Hello, Folks!
I am trying to create dynamic content for an IFrame object within an ASPX page. I did not want to try and pull its content from another page. Previously in ASP.Classic I would use a bunch of Response.Write commands that would spit out a buch of JavaScript code to populate the IFrame like:
<IFrame name="ifrmTarget"> </IFrame>
<%
Response.Write "document.ifrmTarget.writeln('" ... "');"
%>
(I may be a little off on the syntax)
As you can tell this was pretty inefficient because the work of generating the IFrame content was client-side intensive. Things really got slow when I was outputting the results of a query in a table with more than a hundred records!
Now, I would like to do this sort of thing in ASP.NET and VB.NET. From what little I know I am thinking of this approach:
ASPX file:
<IFrame runat="server" id="ifrmTarget" />
Code-behind:
Protected ifrmTarget as HtmlGenericControl
...
ifrmTarget.Attributes.Add("src") = CoughUp()
Will this work?!
Now, I just have to figure out how to conver the output of a DataGrid to a string/HTML output if at all possible.
TIA...
"The early bird may get the work but the second mouse gets the cheese..."