Click here to Skip to main content
15,912,932 members
Home / Discussions / C#
   

C#

 
QuestionMail attachments Pin
damianrda17-Jul-08 8:05
damianrda17-Jul-08 8:05 
QuestionWMI Question Pin
#realJSOP17-Jul-08 6:11
professional#realJSOP17-Jul-08 6:11 
AnswerRe: WMI Question Pin
half-life17-Jul-08 6:21
half-life17-Jul-08 6:21 
AnswerRe: WMI Question Pin
Uros Calakovic17-Jul-08 6:35
Uros Calakovic17-Jul-08 6:35 
AnswerRe: WMI Question Pin
Luc Pattyn17-Jul-08 8:33
sitebuilderLuc Pattyn17-Jul-08 8:33 
GeneralRe: WMI Question Pin
#realJSOP17-Jul-08 8:53
professional#realJSOP17-Jul-08 8:53 
QuestionWhat does @ mean now? Pin
Dirso17-Jul-08 5:38
Dirso17-Jul-08 5:38 
AnswerRe: What does @ mean now? Pin
Luc Pattyn17-Jul-08 5:47
sitebuilderLuc Pattyn17-Jul-08 5:47 
AnswerRe: What does @ mean now? Pin
originSH17-Jul-08 5:47
originSH17-Jul-08 5:47 
GeneralRe: What does @ mean now? Pin
Luc Pattyn17-Jul-08 5:59
sitebuilderLuc Pattyn17-Jul-08 5:59 
GeneralRe: What does @ mean now? Pin
originSH17-Jul-08 6:14
originSH17-Jul-08 6:14 
GeneralRe: What does @ mean now? Pin
Luc Pattyn17-Jul-08 6:38
sitebuilderLuc Pattyn17-Jul-08 6:38 
AnswerRe: What does @ mean now? Pin
Dirso17-Jul-08 5:52
Dirso17-Jul-08 5:52 
AnswerRe: What does @ mean now? Pin
Giorgi Dalakishvili17-Jul-08 5:56
mentorGiorgi Dalakishvili17-Jul-08 5:56 
QuestionData Validation Question Pin
Harvey Saayman17-Jul-08 5:11
Harvey Saayman17-Jul-08 5:11 
AnswerRe: Data Validation Question Pin
half-life17-Jul-08 5:49
half-life17-Jul-08 5:49 
AnswerRe: Data Validation Question Pin
Alan Balkany17-Jul-08 7:35
Alan Balkany17-Jul-08 7:35 
AnswerRe: Data Validation Question Pin
Garrett Pauls17-Jul-08 7:42
Garrett Pauls17-Jul-08 7:42 
I would recommend wiring into all the controls Validating events, then you can just call the forms ValidateChildren method to validate everything. I'd also recommend using an Error Provider, which can display an icon and error tooltip beside each invalid control.

If you'd prefer to keep your current structure for validation and just clean it up a bit, you could use the TimeSpan.TryParse instead of TimeSpan.Parse, like so:
<br />
TimeSpan timeSpan;<br />
if(!TimeSpan.TryParse(maskedTextBox1.Text, out timeSpan)){<br />
//text is invalid<br />
}<br />

GeneralRe: Data Validation Question Pin
Harvey Saayman17-Jul-08 20:07
Harvey Saayman17-Jul-08 20:07 
AnswerRe: Data Validation Question Pin
Green Fuze18-Jul-08 2:33
Green Fuze18-Jul-08 2:33 
GeneralRe: Data Validation Question Pin
Harvey Saayman18-Jul-08 4:54
Harvey Saayman18-Jul-08 4:54 
Questioncreate your own version of arraylist in c#?? Pin
lolla200617-Jul-08 4:42
lolla200617-Jul-08 4:42 
AnswerRe: create your own version of arraylist in c#?? Pin
Christian Graus17-Jul-08 4:58
protectorChristian Graus17-Jul-08 4:58 
GeneralRe: create your own version of arraylist in c#?? Pin
lolla200617-Jul-08 9:39
lolla200617-Jul-08 9:39 
GeneralRe: create your own version of arraylist in c#?? Pin
z3irr19-Jul-08 0:56
z3irr19-Jul-08 0:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.