Y
Yuriy
I need run Java Script on Server Control. I wrote the
following :
<asp:button id="btnMemAddChange1" runat="server" Text="Add
Family Member 1" Width="146px" onclick="openWindow
('./MyForm.aspx','hdBut1')"></asp:button>
It doesn't work "Compilation Error"
There is a javaScript code is working good.
var windowHandle;
function openWindow(myform,sHdnValue) {
var hdvalue;
hdvalue=sHdnValue
if(windowHandle!=null && !
windowHandle.closed){
windowHandle.close();
}
windowHandle=window.open
(myform,'HouseholdMember', 'toolbar=yes, location=no,
status=yes, menubar=no, resizable=yes, scrollbars=yes,
width=500, height=400');
windowHandle.document.myform.hdnVal.value=hdvalue
windowHandle.focus();
return false;
}
following :
<asp:button id="btnMemAddChange1" runat="server" Text="Add
Family Member 1" Width="146px" onclick="openWindow
('./MyForm.aspx','hdBut1')"></asp:button>
It doesn't work "Compilation Error"
There is a javaScript code is working good.
var windowHandle;
function openWindow(myform,sHdnValue) {
var hdvalue;
hdvalue=sHdnValue
if(windowHandle!=null && !
windowHandle.closed){
windowHandle.close();
}
windowHandle=window.open
(myform,'HouseholdMember', 'toolbar=yes, location=no,
status=yes, menubar=no, resizable=yes, scrollbars=yes,
width=500, height=400');
windowHandle.document.myform.hdnVal.value=hdvalue
windowHandle.focus();
return false;
}