开发者

Open window with generated HTML content in ASP.NET?

Is there any possible way of populating a popup window with dynamically created HTML?

Right now, I have this:

HttpContext.Current.Response.Clear();
HttpContext.Current.Response.Write(writer.ToString());
HttpContext.Current.Response.Write("<script>window.print();</script>");
HttpContex开发者_如何转开发t.Current.Response.End();

But it is very unattractive to have the contents be displayed in the original window. I know that I could create a seperate file where I can assemble the query with querystrings and have that pop out, but is there any easier way of doing this?

Many thanks


Write a javascript function that receives HTML as a parameter, opens a new window and populates it with the new HTML. This is not a .NET issue, it's all client-side.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜