• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 280
  • Last Modified:

calendar pop up causes validation...

Hi all,

My textbox control is where the date gets inserted into from a pop up calendar. I have a validation control which fires if no date is selected. So a date must be put in the textbox.

I have a link which makes the calendar control page pop up - however when the page pops up the validation is also fired and because the user hasn't selected a date yet, the validation error message is displayed.

What could be causing this? Is it fixable??

My op-up calendar code:

<A class="calLink" onclick="window.open('calendar.aspx?textbox=txtDate','cal','width=141,height=160')"
                                                                  href="javascript:;"><INPUT type="image" alt="Click for Calendar" src="images/calendarGIF.gif" name="calGIF"></A>

thx,

KS
0
Ramesh Srinivas
Asked:
Ramesh Srinivas
  • 2
1 Solution
 
mmarinovCommented:
Hi,

have you tried to use HyperLink control and set it the javascript but also set it CauseValidation=False ?

Regards,
B..M
0
 
Ramesh SrinivasTechnical ConsultantAuthor Commented:
I did try it at some point, Hyperlink control doesnt have onClick method - which is what I use to call the javascript.

0
 
greenlantern0Commented:
<a onclick="javascript:window.open('calendar.aspx?textbox=txtDate','cal','width=141,height=160');"
                        href="#"><img alt="Click for Calendar" src="images/calendarGIF.gif" name="calGIF" border="0"></a>

Alright, sooo have you tried this?
0
 
Ramesh SrinivasTechnical ConsultantAuthor Commented:
Nope!

Works good tho!

Nice one.

KS
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now