Login or Sign up Help | Site Map
Connecting Tech Pros Worldwide

datalist edit mode and javascript pop up calendar

Question posted by: Ravikanth[MVP] (Guest) on November 17th, 2005 06:02 PM
Hi

Check whether textbox control name is 'txtDischargeDate'
or it contains automatically generated id?

HTH
Ravikanth

[color=blue]
>-----Original Message-----
>Dear ASP.NET Programmers,
>
>I am using a javascript to display popup calendar and[/color]
return the selected[color=blue]
>date to the control in the calling form. No problems[/color]
here. When I use this[color=blue]
>script for a control that is created in datalist edit[/color]
mode, the popup[color=blue]
>calendar doesn't return the date because it cannot find[/color]
the control (or I[color=blue]
>think so). Is there any way to work around this? I use[/color]
the following code:[color=blue]
>
><script language="Javascript">
> function GetDate(ctrlName)
> {
> childWindow = window.open('popup.aspx?formName=' +
> document.forms[0].name + '&ctrlName=' +[/color]
ctrlName, "PopUpCalendar",[color=blue]
> "width=350, height=230, top=200, left=200,[/color]
toolbars=no, scrollbars=no,[color=blue]
>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]
Would you like to answer this question?
Sign up for a free account, or Login (if you're already a member).
buran's Avatar
buran
Guest
n/a Posts
November 17th, 2005
06:02 PM
#2

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]



buran's Avatar
buran
Guest
n/a Posts
November 17th, 2005
06:09 PM
#3

Re: datalist edit mode and javascript pop up calendar
The control name is txtDischargeDate. No problems there. Any suggestions?

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]



 
Not the answer you were looking for? Post your question . . .
173,514 Experts ready to help you find a solution.
Sign up for a free account, or Login (if you're already a member).

  • Didn't find the answer you were looking for?
    Post Your Question
  • Top Community Contributors