I have a page that removes a number of records from the database depending
on the values in the querysting...
i.e
deletemessage.aspx?messageID=1|3|11|42|100
What I do is take this | delimited string and put it into my delete query,
and the records are deleted.
The problem is, if the querystring is too long, this page does not get
called. So I have decided to call the page now, without the querystring.
So what I am trying to do now in my deletemessage.aspx is the following...
1.) Get the values of the messages to be deleted from another frame
2.) Populate a server-side web control on the page with the values from the
other frame
3.) Call the code that deletes all the messages (i.e 1|3|11|42|100) in the
web control.
Note that this all needs to be done in Sub Page_Load as this page that
removes the messages is a hidden iframe and allows no user interaction.
I have tried using JavaScript on #1 i.e
Dim jScriptString2 as String
jScriptString2 = "<SCR" + "IPT>"
jScriptString2 += "alert('hello');"
jScriptString2 += "document.deleteForm.hidMessageID.value
top.mainFrame.WinMail_WinContent.mail_listinbox.listInboxForm.lastRowClicked
.value;"
jScriptString2 += "</SCR" + "IPT>"
Response.Write(jScriptString2)
but obviously document.deleteForm.hidMessageID does not exist yet as it has
not been rendered on the page.
I then tried adding the hidMessageID control in my Page_Load, but I still
get the error that the control does not exist.
Any other ideas how I can get this web control populated from another frame
on page_load?
Greg