[quoted text, click to view] "Divya" <divyas@newmediagateway.com> wrote in message
news:0C991F55-DCC2-4784-991F-644765DEB5EC@microsoft.com...
> Hi,
>
> I am adding a user control to an aspx page dynamically. This user control
has a link button. Hence I have to enclose it in a form tag with
runat=server. When I execute the page, I get a javascript runtime error (;
expected). The error occurs in the asp generated part of the code. The line
where this error occurs is
[quoted text, click to view] > else {theform = document._ctl0:form1;} in the following part of code -
>
> <html><head><meta name="GENERATOR" Content="Microsoft Visual Studio .NET
7.1"><meta name="CODE_LANGUAGE" Content="C#"><meta
name="vs_defaultClientScript" content="JavaScript"><meta
name="vs_targetSchema"
content="
http://schemas.microsoft.com/intellisense/ie5"><title>NMG Digital
Marketing System</title><link href= ..\code\css\default.css
rel='stylesheet' type='text/css'></head><body><table border="1" width="100%"
height="100%"><tr><td align="center" height="20"><h3>NMG Digital Marketing
System</h3></td></tr><tr><td align="center" valign="top"><form id="mainForm"
runat="server" method=post><script language="javascript">
[quoted text, click to view] > document.title = "Manage Admin";
> parent.parent.parent.identifyFrame(this.name, document.title);
> </script><form name="_ctl0:form1" method="post"
action="index.aspx?c=admin.admincp.manageadmin" id="_ctl0_form1"><input
type="hidden" name="__EVENTTARGET" value="" /><input type="hidden"
name="__EVENTARGUMENT" value="" /><input type="hidden" name="__VIEWSTATE"
value="dDwtOTU1NjcwNzcxO3Q8O2w8aTwxMD47PjtsPHQ8O2w8aTwwPjs+O2w8dDw7bDxpPDE+O
z47bDx0PDtsPGk8MT47PjtsPHQ8QDA8cDxwPGw8UGFnZUNvdW50O18hSXRlbUNvdW50O18hRGF0Y
VNvdXJjZUl0ZW1Db3VudDtEYXRhS2V5czs+O2w8aTwxPjtpPDE+O2k8MT47bDxpPDMxPjs+Oz4+O
z47Ozs7Ozs7Ozs7PjtsPGk8MD47PjtsPHQ8O2w8aTwxPjs+O2w8dDw7bDxpPDA+Oz47bDx0PHA8c
DxsPFRleHQ7PjtsPDMxOz4+Oz47Oz47Pj47Pj47Pj47Pj47Pj47Pj47Pj47PkfgL7dJ8B16d6irf
MFLe4UP0jBO" /><script language="javascript"><!--
[quoted text, click to view] > function __doPostBack(eventTarget, eventArgument) {
> var theform;
> if (window.navigator.appName.toLowerCase().indexOf("netscape") > -1) {
> theform = document.forms["_ctl0:form1"];
> }
> else {
> theform = document._ctl0:form1;
> }
> theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
> theform.__EVENTARGUMENT.value = eventArgument;
> theform.submit();
> }
> // --></script><table cellspacing="0" cellpadding="3" rules="all"
border="1" id="_ctl0_dgUsers"
style="height:136px;width:350px;border-collapse:collapse;"><tr><td
style="font-weight:bold;">User Email
Address</td><td> </td><td> </td></tr><tr><td></td><td
style="width:30px;"><a
href="javascript:__doPostBack('_ctl0$dgUsers$_ctl2$_ctl0','')">Edit</a></td>
<td style="width:30px;"><a
href="javascript:__doPostBack('_ctl0$dgUsers$_ctl2$_ctl1','')">Delete</a></t
d></tr></table></form></form></td></tr><tr><td align="center"
height="20"><i>Copyright 1998 - New Media Gateway,
Inc.</i></td></tr></table></body></html>
[quoted text, click to view] >
> I am loading the static HTML part of the above page from a template file
and I am dynamically loading the user control (manageadmin.ascx).
> How do I solve this problem? Could someone please help?
This is a known problem in ASP.NET 1.1. There is a patch, but I'm afraid
I've misplaced the number of the KB article.
--
John Saunders
johnwsaundersiii at hotmail