Click here to Skip to main content
15,895,786 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am developing a desktop application in c#.
i want to validate my all field before it will save to database ?
Posted
Comments
OriginalGriff 30-Oct-12 4:23am    
And you have our permission if that is what you are waiting for.
Otherwise, we will need more information before we can help you, such as some idea of where you are stuck...

You can use Validating event for textbox (or) In the button click event you can check the value particular text box with the Text property using its ID(i.e., Name in case of desktop applications).
 
Share this answer
 
Well, it depends upon your requirement.
I will suggest you to use Regular Expressions (Regex) if you wanted to get input in specific pattern or for just use KeyPress Event to filter out Alphabetic or Numeric Values or else.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900