473,386 Members | 1,764 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,386 software developers and data experts.

Form state change

Hi.

This is probably easy but I can't find solution so far.

I have a web form with several text boxes.
System.Web.UI.WebControls.TextBox
One submit button
System.Web.UI.WebControls.Button
When button is clicked form submitts fine.
I need to know if used changed any of the textboxes wihtout any specific
events to any of textboxes.
I know I can save the old values and then compare but is not there something
automatic in ASP.Net to track that?

Thanks.
AT
Nov 18 '05 #1
1 999
Hi,

I'm not sure what you mean about "without any specific events to any of
textboxes". The TextBox server controls has a TextChanged event that you
can hook up to every text box. One event can cover all text boxes if you
have them all handled by the same event. Other than that you'll have to use
javascript and a hidden field.

<input type="hidden" id="hidChanged" name="hidChanged" runat="server">

Set this to 0. Then for each textbox:

TextBox1.Attributes.Add("onkeydown",
"document.GetElementById('hidChanged').value = 0;")

Then on your post back check if hidChanged.Value still equals 0. Good luck!
Ken.

--
Ken Dopierala Jr.
For great ASP.Net web hosting try:
http://www.webhost4life.com/default.asp?refid=Spinlight
If you sign up under me and need help, email me.

"Anatoli Trifonov" <sp**@avwork.com> wrote in message
news:Ow**************@TK2MSFTNGP15.phx.gbl...
Hi.

This is probably easy but I can't find solution so far.

I have a web form with several text boxes.
System.Web.UI.WebControls.TextBox
One submit button
System.Web.UI.WebControls.Button
When button is clicked form submitts fine.
I need to know if used changed any of the textboxes wihtout any specific
events to any of textboxes.
I know I can save the old values and then compare but is not there something automatic in ASP.Net to track that?

Thanks.
AT

Nov 18 '05 #2

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

Similar topics

2
by: iwasinnihon | last post by:
I don't usually like to do this, but I need help. I have gone over this code and cannot figure out why it doesn't work. First of all it doesn't check to see if you have filled in the required...
2
by: Edward | last post by:
The below code builds 2 tables 4 rows by 4 cols. All cells have checkboxes. When checked, the checkboxes in the first column automatically check the remainder of the check boxes in the same row. ...
3
by: Nancy | last post by:
Hi, I am working on a project where I have to make a form list static, i.e. put in links so that users can choose a local file. As it stands, it's looking for a php file. Here's an example of the...
10
by: Doug O'Leary | last post by:
Hey, all. I have a perl script which generates the html listed below. I cleaned it up a bit since the perl CGI module creates some really ugly html code. I've looked at this thing 8 ways to...
0
by: kammaldeep | last post by:
hi, i m newbie 2 PHP & to b frank ... will alwaz be ... i dont think i will go into much details with PHP as my work doesnot include workin with PHP bt i have a forum .. and i want to make a...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.