如何在另一个aspx页面中包含aspx页面?在asp.net [英] how to include aspx page in another aspx page? in asp.net

查看:101
本文介绍了如何在另一个aspx页面中包含aspx页面?在asp.net的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用自定义Web应用程序,并且由于我有很多单独的块想将它们放在不同的页面上,所以我想知道如何在现有页面上包含aspx内容?我询问aspx而不是自定义Web控件的原因是因为我计划在这些单独的页面上使用pagemethod.另一个原因是,我看到有人说我们可以做到,但现在找不到链接,所以我想也可以尝试,因为它看起来很整洁:)谢谢

I'm working on a custom web application and because I have many separate blocks I want to put them on a different page, I was wondering how can I include aspx content on existing page? the reason I'm asking about aspx, and not custom web controls, is because I planned to use pagemethods on those separate pages. Another reason is that I saw someone some saying we can do that, can't find the link now, so thought I'll try too, since it looks very neat:) Thanks

推荐答案

Server.Execute(secondUrl)可能会做您想要的事情.但是UserControls绝对是ASP.Net-ish:).

Server.Execute (secondUrl) might do what you want. But UserControls are definitely more ASP.Net-ish :).

这篇关于如何在另一个aspx页面中包含aspx页面?在asp.net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆