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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Datagridview cell validating

Status
Not open for further replies.

cs2009

Programmer
Aug 10, 2009
50
US
Using Visual Studio 2008.

I need some help with how to validate a cell in a datagridview.

I only want to allow the user to enter characters A-Z, a-z, 0-9 and - (hyphen).

Thanks.
 
You could use a custom field validator,so that the field only takes those characters. Place the validator next to the textbox of course
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top