locked
Load all pages from one page RRS feed

  • Question

  • User-804887599 posted

    I've got a scenario where we need get the HTML content of one certain part of each page (that derive from a base class).

    Within a method on a page (in the C# code behind), I want to load each derived page class, load it, and get the HTML, all based on the page name.

    I'm able to construct an instance of each derived page class, but how can I call the Page Load method of it? Note that this is from an ASP.Net page.

    Thanks!

    Chris

    Wednesday, October 25, 2017 7:12 PM

All replies

  • User347430248 posted

    Hi CCusson15,

    from the description of the thread, it looks like you only want to load the specific part of another web pages in your current web page.

    try to use iframe to show the specific part of the web page.

    example:

    <iframe scrolling="no" src="http://www.w3schools.com/css/default.asp" style=border: 0px none; margin-left: -185px; height: 859px; margin-top: -533px; width: 926px;>

    Reference:

    iFrame: How to show specific part of a webpage using iframe <!-- .entry-title -->

    other then that , it is good if you try to create multiple div's on your current page which display the specific contents you want to display.

    then you can try to show and hide div's according to your requirement.

    you can also use the code and events of C#.

    Regards

    Deepak

    Thursday, October 26, 2017 1:57 AM