Basic Javascript question

A

Ashok Gopalan

How do I attach a client-side validation script in a web form page for a
text box control. The intellisense dropdown does not show the common
"OnChange" event.

Any help is greatly appreciated.

Regards,
AG
 
D

Dune

I think you need to use the textchanged event, the
intellisense dropdown lets you choose "ontextchanged".

Hope this helps :)
 
S

srinivas moorthy

Hi
Here is a sample code which is used to attach a server
side control to the client side javascript.

txtSenderName.Attributes.Add("onClick","return doValidate
();");
<controlname>.Attributes.Add("<event name of the
control>","<javascript function name>");

thanks
srinivas moorthy
 
A

Ashok Gopalan

Thanks for your prompt response. Appreciate it!

If I use the "OnTextChanged" event, I get a compile error; in fact I do not
get any errors if I choose "Onchange" event even though the event is not
available in intellisense. I would assume that one can only code for those
members that show up in intellisense. Maybe I am wrong!! Would appreciate
any further clarification.

Thanks

AG

Thanks for your prompt response. Appreciate it!

If I use the "OnTextChanged" event, I get a compile error; in fact I do not
get any errors if I choose "Onchange" event even though the event is not
available in intellisense. I would assume that one can only code for those
members that show up in intellisense. Maybe I am wrong!! Would appreciate
any further clarification.

Thanks

AG

Thanks for your prompt response. Appreciate it!

If I use the "OnTextChanged" event, I get a compile error; in fact I do not
get any errors if I choose "Onchange" event even though the event is not
available in intellisense. I would assume that one can only code for those
members that show up in intellisense. Maybe I am wrong!! Would appreciate
any further clarification.

Thanks

AG
 

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,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top