Hi everyone-
I'm using response.write in an asp.net codebehind to add some javascript to the http response:
Response.Write("<script language=" & Chr(34) & "javascript" & Chr(34) & "> document.getElementById('PageContentFrame').src='WebForm3.aspx' </script>")
Basically, I want this to set the contents of an iframe. However, it appears that when this javascript fires, the page hasn't been rendered yet, so there's no object there for it to set the location for. I don't know when/where the response.write goes.
Does anyone have any suggestions about how to get around this?
Thanks!
I'm using response.write in an asp.net codebehind to add some javascript to the http response:
Response.Write("<script language=" & Chr(34) & "javascript" & Chr(34) & "> document.getElementById('PageContentFrame').src='WebForm3.aspx' </script>")
Basically, I want this to set the contents of an iframe. However, it appears that when this javascript fires, the page hasn't been rendered yet, so there's no object there for it to set the location for. I don't know when/where the response.write goes.
Does anyone have any suggestions about how to get around this?
Thanks!