473,324 Members | 2,541 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

recognize the change of controls value in javascript

hi.
Is there any body to help me?
I am writing a web program.
I have some forms.
each form have some controls and users can edit the controls.
finally they can save their forms.
I would like to add an ability to my program.
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
I want to write my code with javascript and I wouldn't like to work
with the server.
In fact all the story happen at the clients side.
I think that checking the Control's value with values of Database or a
copy of database that exist in memory in the specific time is not a
good way.

Jun 20 '07 #1
5 1840
On Jun 20, 5:19 pm, raha <bighamor...@gmail.comwrote:
hi.
Is there any body to help me?
I am writing a web program.
I have some forms.
each form have some controls and users can edit the controls.
finally they can save their forms.
I would like to add an ability to my program.
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
I want to write my code with javascript and I wouldn't like to work
with the server.
In fact all the story happen at the clients side.
I think that checking the Control's value with values of Database or a
copy of database that exist in memory in the specific time is not a
good way.
Maybe using the onchange event on the inputs?

Jun 20 '07 #2
Darko said the following on 6/20/2007 1:58 PM:
On Jun 20, 5:19 pm, raha <bighamor...@gmail.comwrote:
>hi.
Is there any body to help me?
I am writing a web program.
I have some forms.
each form have some controls and users can edit the controls.
finally they can save their forms.
I would like to add an ability to my program.
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
I want to write my code with javascript and I wouldn't like to work
with the server.
In fact all the story happen at the clients side.
I think that checking the Control's value with values of Database or a
copy of database that exist in memory in the specific time is not a
good way.

Maybe using the onchange event on the inputs?
That won't satisfy the desire though. If an input starts with a value of
"Default Value" and I manually change it to "Manual Value", then I
change my mind and type in "Default Value", did the value of the input
change? defaultValue is the property wanted to check against, not simply
that the value has changed.

onchange="if(this.value!=this.defaultValue){change TheIcon('changed'}else{changeTheIcon('default')}"

And then have changeTheIcon change the icon dependent on the parameter
passed to it.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Jun 20 '07 #3
On Jun 20, 11:41 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Darko said the following on 6/20/2007 1:58 PM:
On Jun 20, 5:19 pm, raha <bighamor...@gmail.comwrote:
hi.
Is there any body to help me?
I am writing a web program.
I have some forms.
each form have some controls and users can edit the controls.
finally they can save their forms.
I would like to add an ability to my program.
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
I want to write my code with javascript and I wouldn't like to work
with the server.
In fact all the story happen at the clients side.
I think that checking the Control's value with values of Database or a
copy of database that exist in memory in the specific time is not a
good way.
Maybe using the onchange event on the inputs?

That won't satisfy the desire though. If an input starts with a value of
"Default Value" and I manually change it to "Manual Value", then I
change my mind and type in "Default Value", did the value of the input
change? defaultValue is the property wanted to check against, not simply
that the value has changed.

onchange="if(this.value!=this.defaultValue){change TheIcon('changed'}else{changeTheIcon('default')}"

And then have changeTheIcon change the icon dependent on the parameter
passed to it.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ -http://jibbering.com/faq/index.html
Javascript Best Practices -http://www.JavascriptToolbox.com/bestpractices/
And if you open MS Word and find the text "Default text" and then you
change it to "Modified text" and then manually back to "Default text"
do you think it will consider the document modified or not?

Jun 21 '07 #4
Darko said the following on 6/21/2007 11:15 AM:
On Jun 20, 11:41 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
>Darko said the following on 6/20/2007 1:58 PM:
>>On Jun 20, 5:19 pm, raha <bighamor...@gmail.comwrote:
hi.
Is there any body to help me?
I am writing a web program.
I have some forms.
each form have some controls and users can edit the controls.
finally they can save their forms.
I would like to add an ability to my program.
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
I want to write my code with javascript and I wouldn't like to work
with the server.
In fact all the story happen at the clients side.
I think that checking the Control's value with values of Database or a
copy of database that exist in memory in the specific time is not a
good way.
Maybe using the onchange event on the inputs?
That won't satisfy the desire though. If an input starts with a value of
"Default Value" and I manually change it to "Manual Value", then I
change my mind and type in "Default Value", did the value of the input
change? defaultValue is the property wanted to check against, not simply
that the value has changed.

onchange="if(this.value!=this.defaultValue){chang eTheIcon('changed'}else{changeTheIcon('default')}"

And then have changeTheIcon change the icon dependent on the parameter
passed to it.
And if you open MS Word and find the text "Default text" and then you
change it to "Modified text" and then manually back to "Default text"
do you think it will consider the document modified or not?
Let me think on this one for a minute and consider a few things:

1) This is a Javascript Newsgroup
2) This newsgroup has nothing to do with MS Word.
3) I don't use MS Word, I use a real Word Processor.
4) What happens in Word has nothing to do with what happens in a browser
unless you are trying to emulate it.
5) I didn't change my mind after thinking about it, I still don't care
what MS Word does. If you want to know if a field has changed from it's
default value then onchange alone will not suffice.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Jun 21 '07 #5
On Jun 21, 6:25 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
Let me think on this one for a minute and consider a few things:

1) This is a Javascript Newsgroup
2) This newsgroup has nothing to do with MS Word.
3) I don't use MS Word, I use a real Word Processor.
4) What happens in Word has nothing to do with what happens in a browser
unless you are trying to emulate it.
5) I didn't change my mind after thinking about it, I still don't care
what MS Word does. If you want to know if a field has changed from it's
default value then onchange alone will not suffice.
On Jun 20, 5:19 pm, raha <bighamor...@gmail.comwrote:
In fact I want to have an Icon that change, when a user change the
value of a control of form such as textbox , radiobox, grid.
as you know the most famous and important editors such as PSPAD or
MSWORD have this ability.
Jun 21 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Marc Castrechini | last post by:
I have a page that changes an <ASP:Checkbox value based on a user entered value in a textboxm using client side Javascript. After my submit is fired the value for the chkMyCB.checked does not get...
4
by: Ptaku25 | last post by:
How to catch whole line in the PDF document using javascript? or How to recognize/catch whitespace signs (e.g. "\n" ) in PDF document Which method I should use? Or any other possibility are ? ...
1
by: Krish | last post by:
Hi, I am using table control to create table/cell & 2 text box & one image button during runtime. Onclick event of image button i would like to validate if there is any value in either of text...
1
by: richardscheff | last post by:
Video selector works for IE but not other browsers. for not IE <object ID='Player' data="video/dodgeball.wmv" type="video/x-ms-wmv" width="320" height="280"> <param name="filename"...
4
by: Erland | last post by:
Hello everyone, I am have couple of bad concepts and would like to clear things up. As I understand ASP.NET server controls contain runat=server tag and they only run on the server. But I've...
4
by: Jo Claes | last post by:
Hi, A friend asked me if i could help him building a lilttle website. Having 10 years of proffessional experiance in writing "non-webbased" code i thought that will not be that hard. I think...
1
by: SeanBoyWalton | last post by:
Hi, I'm currently trying to build a website for a DJ friend of mine and I have come stuck with a couple of issues. I've searched everywhere and put some code together but I still have problems. ...
78
by: Jeremy J Starcher | last post by:
(Request for Discussion) I've put together a guide that I hope will help novice coders avoid the same hair pulling that I went through. I'm open for comments about it. Have I missed the...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.