bostongeorge
bostongeorge

Reputation: 85

open HTML page from c#/asp.net

Is it possible from c#/asp.net to call/show a separeted html-page in the same window.

I don't want to store the entire html code into a , for exemple... (that works).

Possible with javascript? or do I have to modify the code-behind?

The purpose is to load this html page everytime the default.aspx is invoked, as a webform(pop-up)

Upvotes: 0

Views: 890

Answers (2)

Pawan
Pawan

Reputation: 1744

You can Use iframe to open your .html page as:

.aspx Page:

<iframe id="ifrm" runat="server"></iframe>

And on Page_Load(code behind):

protected void Page_Load(object sender, EventArgs e)
{ 
   ifrm.Attributes["src"] = "yourHtmlpageURL.html";
}

Upvotes: 1

sms247
sms247

Reputation: 4504

You can use it asp.net

<iframe src="http://www.google.com"></iframe>

For c# application you can use WebBrowserControl.

Upvotes: 0

Related Questions