Embed an html page into a placeholder?

J

John

Hi all,

My web app uses 3 different placeholders on one page and dynamically load
usercontrols into them. That's all fine but now I have two situations which
puzzle me:

1. I have a sub-folder of html pages from my site and I need to show one of
these pages at a time within a specific placeholder on my main page. How do
I go about doing this?

2. I have a dll which creates a server-side spreadsheet and I also need to
load this spreadsheet into a placeholder. How do I do this?

Any help forth-coming would be really appreciated.

Regards
John.
 
M

Martin Dechev

Hi, John,

1. I have a sub-folder of html pages from my site and I need to show one of
these pages at a time within a specific placeholder on my main page. How do
I go about doing this?

You can use an iframe control. Just add runat="server" and an id attributes.
Declare it as System.Web.UI.HtmlControls.HtmlGenericControl in the page
class. You can set the src, width, height, etc properties from the page
class like this:

[C#]
iframe1.Attributes["src"] = "the src";
[VB.NET]
iframe1.Attributes("src") = "the src"
2. I have a dll which creates a server-side spreadsheet and I also need to
load this spreadsheet into a placeholder. How do I do this?

I'm only guessing as I don't know what this "server-side spreadsheet" looks
like. Create a usercontrol that will take this "spreadsheet" as parameter
and display the data contained in it somehow as html.

Greetings
Martin
 
J

John

Martin,

Worked perfectly.

Thank you.
John.

Martin Dechev said:
Hi, John,

1. I have a sub-folder of html pages from my site and I need to show one of
these pages at a time within a specific placeholder on my main page. How do
I go about doing this?

You can use an iframe control. Just add runat="server" and an id attributes.
Declare it as System.Web.UI.HtmlControls.HtmlGenericControl in the page
class. You can set the src, width, height, etc properties from the page
class like this:

[C#]
iframe1.Attributes["src"] = "the src";
[VB.NET]
iframe1.Attributes("src") = "the src"
2. I have a dll which creates a server-side spreadsheet and I also need to
load this spreadsheet into a placeholder. How do I do this?

I'm only guessing as I don't know what this "server-side spreadsheet" looks
like. Create a usercontrol that will take this "spreadsheet" as parameter
and display the data contained in it somehow as html.

Greetings
Martin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,733
Messages
2,569,439
Members
44,829
Latest member
PIXThurman

Latest Threads

Top