Solved

calendar pop up causes validation...

Posted on 2004-08-17
4
266 Views
Last Modified: 2013-11-28
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
Comment
Question by:saleek
  • 2
4 Comments
 
LVL 28

Expert Comment

by:mmarinov
ID: 11821499
Hi,

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

Regards,
B..M
0
 
LVL 11

Author Comment

by:saleek
ID: 11821679
I did try it at some point, Hyperlink control doesnt have onClick method - which is what I use to call the javascript.

0
 
LVL 1

Accepted Solution

by:
greenlantern0 earned 50 total points
ID: 11821769
<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
 
LVL 11

Author Comment

by:saleek
ID: 11821977
Nope!

Works good tho!

Nice one.

KS
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Digital marketing agencies have encountered both the opportunities and difficulties that emerge from working with a wide-ranging organizations.
In this blog, I will share you some basic tips for content marketing and to rank your website on Google.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
Use Wufoo, an online form creation tool, to make powerful forms. Learn how to selectively show certain fields based on user input using rules to gather relevant information and data from your forms. The rules feature provides you with an opportunity…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question