Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

reset input text

Status
Not open for further replies.

janet24

Technical User
Jul 22, 2003
161
US
I have input text where people can answer a question. After they type something in the input field I want to reset or clear the text field.

When I set the Variable to 0 or null, I get a 0 or null in the input text. When I do nothing the previous answers stay in the text field. How do I reset it?

Thanks...

 
my_var = "";

Regards,

cubalibre2.gif
 
Thanks...I just realized that this works also!

my_var=check


 
I can't remember why I tried check or why it worked....I'll use the

my_var = "";
 
Well, if in fact check = ""; then that would also work.

Regards,

cubalibre2.gif
 
my_var = check

will work fine as it returns a boolean value if check is not a previously defined variable but without seeing more code its hard to see why you would use that instead of just setting it to blank
 
I used it because I didn't know what I was doing....and it worked. I used my_var = "";
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top