File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes HTML, CSS and JavaScript and the fly likes OnChange and Calander popup Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "OnChange and Calander popup" Watch "OnChange and Calander popup" New topic
Author

OnChange and Calander popup

Sujatha Kalluri
Ranch Hand

Joined: Oct 09, 2002
Posts: 33
Hi,

I have a text field on which I am writing onChange event. The value of text field is getting changed by calander popup by selecting date from calander, but onChange event is not fired unless I manually change the text field, how can we force the event to fire when date is selected by calander popup.

any hints please...??

here is my onchange code


David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

I believe (but could be wrong) onchange is specifically for UI events; it wouldn't fire if you populated it via a simple jQuery call, either.

Maybe hook into the widget code, or use onblur?
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
When you use event handlers, do not use javascript:

onchange does not get fired when you change the value with JavaScript. It only gets fired when a person changes the value. The Calendar code should have an event build in when the user selects a date. If it does not, than that is a poor component.

Eric
Sujatha Kalluri
Ranch Hand

Joined: Oct 09, 2002
Posts: 33
David Newton wrote:I believe (but could be wrong) onchange is specifically for UI events; it wouldn't fire if you populated it via a simple jQuery call, either.

Maybe hook into the widget code, or use onblur?


How do I use the onBlur with calander popup

sK
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Please see Eric's response.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: OnChange and Calander popup