I have a main web page which opens a modal web page and passes an integer argument into the modal page:-
I then have the following javascript funtion to set the modal argument into a hidden html field so that I can access it:-
The above is run on the client like this:-
This all works great.
The problem I have is that I now need to access the passed argument in the modal forms Page_Load event. How can I access the value on the server before the page is generated and sent back to the browser because obviously the do_init function hasn't ran on the client so the value is not in the hidden field. I am just gettig to grips with this Client/Server stuff and the help would be much appreciated.
Many Thanks
Code:
function open_modal(intSearchType)
{
var WinSettings = "status:no;dialogWidth:520px;dialogHeight:250px;dialogHide:true;help:no;scroll:no";
window.showModalDialog("GeneralItem.aspx", intSearchType, WinSettings);
I then have the following javascript funtion to set the modal argument into a hidden html field so that I can access it:-
Code:
function do_init()
{
var intSearchType = window.dialogArguments;
document.getElementById("pass_field").value = intSearchType;
}
The above is run on the client like this:-
Code:
<BODY onload="do_init();" ms_positioning="GridLayout">
This all works great.
The problem I have is that I now need to access the passed argument in the modal forms Page_Load event. How can I access the value on the server before the page is generated and sent back to the browser because obviously the do_init function hasn't ran on the client so the value is not in the hidden field. I am just gettig to grips with this Client/Server stuff and the help would be much appreciated.
Many Thanks