或者假设你新建的母版页是sellMgr.Master
<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="sellMgr.Master" title="原来页面的title" CodeBehind="test.aspx.cs" Inherits="test" %>
<asp:Content ContentPlaceHolderID ="ContentPlaceHolder1" ID="contid" runat="server" >
<link href="../css/form.css" rel="stylesheet" type="text/css" />
<div id="TreeDiv" runat="server" style="overflow:autoz-index:400pxdisplay:blockmargin-top:0px ">
<asp:TreeView ID="TreeView1"runat="server" Width="192px" ShowLines="True"
ShowCheckBoxes="All"
ExpandDepth="1" >
</asp:TreeView>
</div>
</asp:Content>
只需在最上边page里添加一个引用MasterPageFile 、添加一个title
然后把之前网页的JS、css引用 以及form内的代码 放到content内就可以了
欢迎提问
把现有的aspx页面<HTLM>和<BODY><HEAD>以及<%@ Page >等去掉 用<% @ Page Language="C#" MasterPageFIle="你的母版页" AutoEventWireuq ="true" CodeFile="现有页面的后置代码" Inherits="_现有页面(不要.aspx) " title="" %><asp:Content Id="Content1" ContertPlaceHolderId="母版页中ContentPlaceHoder控件的ID" Runat="Server">
(这里放你的Form和Tablet等)
</asp: content>
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)