how to include aspx page in another aspx page? in asp.net
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 abou开发者_运维知识库t 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) might do what you want. But UserControls are definitely more ASP.Net-ish :).
Based on what you describe, the proper answer is custom controls as they allow you to place the code anywhere on any page in an easily reusable manner.
Can you explain what you mean by "aspx content" - is that just html, is it controls? Also, what Page methods are you referring to?
精彩评论