Prepare for your Next Interview
This is a discussion on Textfield onchange function... within the HTML & CSS forums, part of the Web Development category; In my html page, i am using the following code. input type="text" name="result" id="res" value="PASS" onchange="change_result();" The above function is working when the user change ...
|
|||
|
Textfield onchange function...
In my html page, i am using the following code.
input type="text" name="result" id="res" value="PASS" onchange="change_result();" The above function is working when the user change the text on the textfield. But if i change the value of the textfield dynamically(using javascript function)it is not working. Can anyone tell me why is not working? which function i am using here? -------------------- suresh |
| Sponsored Links |
|
|||
|
Re: Textfield onchange function...
S...even i also face the same problem...
I just give one example , check it out whether it works...... Example: function fun1() { if(document.f.na.value=="hello") { } else { alert("Text Changed") } } function fun2() { var mylist=document.getElementById("lang") document.getElementById("na").value=mylist.options[mylist.selectedIndex].text } form name=f> Language : select id=lang onchange=fun2(),fun1()> option selected>Java option>J2ME option>C# option>Dot Net /select> Favorite Language is :input type=Text name=na value="hello" onchange=fun1()> /form> Last edited by daisy_deepa : 06-02-2007 at 09:23 AM. |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How does indexes function? | Lokesh M | SQL | 10 | 10-07-2007 02:13 PM |
| pl/sql function | gujjar | Oracle Certification | 3 | 02-22-2007 10:47 AM |
| yellow color textfield.... | psuresh1982 | HTML & CSS | 2 | 02-03-2007 09:07 AM |
| TSL Function | sutnarcha | WinRunner | 1 | 12-20-2006 05:40 AM |
| Function in PHP | sripri | PHP | 1 | 07-20-2006 12:13 PM |