简体   繁体   English

vb.net中的母版页需要2页的过程

[英]master page in vb.net needs to be a 2 page process

The question is exactly as the title sounds. 问题恰如标题听起来一样。 I have 1 master page in asp.net(vb.net). 我在asp.net(vb.net)中有1个母版页。 now this master page has 1 form which has 10 textboxes in it. 现在,该母版页具有1个表单,其中包含10个文本框。 On the other hand the master page has about 10 different links in it (outside the form), that link to different pages. 另一方面,母版页中大约有10个不同的链接(在表单之外),这些链接指向不同的页面。 My question is how do i keep all this same way, and only divide the form in 2 pages. 我的问题是我如何保持所有这些相同的方式,并且只将表格分为两页。 5 textboxes for first and 5 textboxes for second. 第一个5个文本框,第二个5个文本框。 So basically when master page loads, it doesnt show the 10 textboxes as original, but shows only first 5, and when clicked "continue", the next 5 textboxes load on the same place as the first 5 were. 因此,基本上,在加载母版页时,它不会显示原始的10个文本框,而是仅显示前5个,单击“继续”时,接下来的5个文本框将与前5个文本框加载在同一位置。 The rest of links in page and rest of the page, remains exactly the same. 页面中的其余链接与页面中的其余链接保持完全相同。

A master page is used for templating. 母版页用于模板。 What you do is take the "rest of links in page [sic] and rest of the page" and keep them in the master page. 您要做的是“保留页面[sic]中的其余链接和页面的其余部分”,并将其保留在母版页中。 But instead of you textboxes you add a content place holder to the page. 但是,您可以在页面上添加内容占位符,而不是文本框。 You then put two normal aspx pages in your project, and set them to fill the placeholder you just created on the master page. 然后,在项目中放置两个普通的aspx页面,并将它们设置为填充刚在母版页上创建的占位符。

Firstly I don't think you're using the term Master Page the way it should be used. 首先,我不认为您使用的术语是“母版页”。 A master page should hold other pages ( .master -> .aspx ). 母版页应包含其他页面( .master > .aspx )。

Secondly, you should check out the ASP.NET Wizard control 其次,您应该签出ASP.NET向导控件

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM