Alan,

You can do something like this:

Add >> onChange="onChangeHandler(this)" << to the Html tag for textbox using
ExtraHtml property in the ND Studio.

Inside >> function onChangeHandler(textBox) <<
textBox.name, textBox.value etc give you the required information.

If you don't like the value entered by the user, after giving an alert
message you can do:
textBox.value = "<whatever>";
textBox.focus();

The value will change and the focus will go back to the textbox.

(All these works perfectly with Netscape. I remember having problems with
IE, and don't know if it works with later versions, nor what standards they
follow as far as JS is concerned). 

For reference on JS supported by NS, you can go to:
http://developer.netscape.com/docs/manuals/js/client/jsref/index.htm


Aby Mathew
TeamND


> -----Original Message-----
> From: Alan D'Cunha [mailto:[EMAIL PROTECTED]]
> Sent: Friday, November 19, 1999 10:54 AM
> To: Aby Mathew
> Subject: RE: [ND] JavaScript Issues
> 
> 
> i have to set up Javascript validations for a text
> box.
> 
> but if the user makes a mistake the alert box pops up
> ... but after you press OK .. the text box remains
> with an improper format.
> 
> how can u ensure that the user ONLY types in proper
> format...
> 
> so basically i want to know how i can get back to the
> text box after the alert message is triggered by the 
>             Onchange event
> 
> 
> thanks
> 
> 
> --- Aby Mathew <[EMAIL PROTECTED]> wrote:
> > Pls try to be more specific about what you want to
> > achieve, what you are
> > trying to do and what problem you encounter. At
> > least the first part - what
> > you want to achieve. Help is likely to come much
> > faster. I know there are
> > plenty of Javascript experts in the forum.
> > 
> > Regards,
> > 
> > Aby
> > TeamND
> > 
> > > -----Original Message-----
> > > From: Alan D'Cunha [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, November 19, 1999 8:45 AM
> > > To: [EMAIL PROTECTED]
> > > Subject: [ND] JavaScript Issues
> > > 
> > > 
> > > 
> > > hi,
> > > 
> > > i was trying some validations via JavaScript and i
> > am not 
> > > able to restrict the user to perform any other
> > opertaion on 
> > > the screen without succescfully entering data into
> > text boxes..
> > > 
> > > i hope that some of you can give me some help on
> > this topic, in NETDYN
> > > 
> > > thanks
> > > 
> > > Al
> > >
> >
> ______________________________________________________________
> > > ___________
> > > 
> > > For help in using, subscribing, and unsubscribing
> > to the discussion
> > > forums, please go to: 
> > >
> > http://www.netdynamics.com/support/visitdevfor.html
> > > 
> > > For dire need help, email: [EMAIL PROTECTED]
> > > 
> > 
> 
> 
> =====
> and remember...,
> 
> Keep smiling...you look so much better when u do!!!
> __________________________________________________
> Do You Yahoo!?
> Bid and sell for free at http://auctions.yahoo.com
> 
_________________________________________________________________________

For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html

For dire need help, email: [EMAIL PROTECTED]

Reply via email to