| re: datalist edit mode and javascript pop up calendar
The control name is 'txtDischargeDate' and it is automatically created when
in edit mode. How can I reference it in Javascript?
Buran
"Ravikanth[MVP]" <dvravikanth@hotmail.com> wrote in message
news:04ef01c34d14$906ea1c0$a001280a@phx.gbl...[color=blue]
> Hi
>
> Check whether textbox control name is 'txtDischargeDate'
> or it contains automatically generated id?
>
> HTH
> Ravikanth
>
>[color=green]
> >-----Original Message-----
> >Dear ASP.NET Programmers,
> >
> >I am using a javascript to display popup calendar and[/color]
> return the selected[color=green]
> >date to the control in the calling form. No problems[/color]
> here. When I use this[color=green]
> >script for a control that is created in datalist edit[/color]
> mode, the popup[color=green]
> >calendar doesn't return the date because it cannot find[/color]
> the control (or I[color=green]
> >think so). Is there any way to work around this? I use[/color]
> the following code:[color=green]
> >
> ><script language="Javascript">
> > function GetDate(ctrlName)
> > {
> > childWindow = window.open('popup.aspx?formName=' +
> > document.forms[0].name + '&ctrlName=' +[/color]
> ctrlName, "PopUpCalendar",[color=green]
> > "width=350, height=230, top=200, left=200,[/color]
> toolbars=no, scrollbars=no,[color=green]
> >status=no, resizable=no");
> > }
> >
> > function CloseWindow()
> > {
> > childWindow.close()
> > }
> > </script>
> > <script language="JavaScript">
> >
> ><A href="javascript:GetDate('txtDischargeDate')"><IMG
> >src="images/smallcalendar.gif" border="0"></A>
> >
> >Thanks in advance,
> >
> >Buran
> >
> >
> >.
> >[/color][/color] |