Causing an event to fire

G

Guest

In asp.net, I have a hyperlink, hypTradeDate. This calls a Calendar page
that has a calendar control. Anyways, it is using some javascript to set the
field, TradeDate.Text.

Anyways, my problem is that I have an even hander on TradeDate.TextChanged.
This isn't getting fired from the javascript. How can I force this to be
fired?
 
G

Guest

Hi Patrick,

One possible reason might be you set the readonly property to the
textbox. If you want to validate the date entered by the user directly,
write a function and add it as 'onblur' event attibute to the 'TradeDate'
textbox.

Hope this will help you.

-Ravi
 
G

Guest

That part I have already conquered. Thanks for responding.

Any thoughts about the other situation? A user clicks a hyperlink, it takes
them to a page with a calendar, the date is selected and set in the text box.
However, no event is fired.
 
W

William F. Robertson, Jr.

In javascript, the event is "onchange". Are you expecting the handle the
event on the client?

On the server it is TextChanged. If the control is disabled on the client
side, the new values are not posted back to the server and the server side
TextChanged event is not fired.

bill
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top