Click here to Skip to main content
11,434,743 members (46,716 online)
   

C#

 
QuestionC# Windows application not responding after 30 minutes Pin
sujithkumarsl2-Oct-12 11:13
membersujithkumarsl2-Oct-12 11:13 
AnswerRe: C# Windows application not responding after 30 minutes Pin
Smart Arab2-Oct-12 11:58
memberSmart Arab2-Oct-12 11:58 
AnswerRe: C# Windows application not responding after 30 minutes Pin
Dave Kreskowiak2-Oct-12 13:35
mvpDave Kreskowiak2-Oct-12 13:35 
GeneralOT Pin
Peter_in_27802-Oct-12 23:08
memberPeter_in_27802-Oct-12 23:08 
GeneralRe: OT Pin
Dave Kreskowiak3-Oct-12 3:22
mvpDave Kreskowiak3-Oct-12 3:22 
GeneralRe: OT Pin
Peter_in_27803-Oct-12 3:29
memberPeter_in_27803-Oct-12 3:29 
GeneralRe: OT Pin
Dave Kreskowiak3-Oct-12 6:24
mvpDave Kreskowiak3-Oct-12 6:24 
GeneralRe: C# Windows application not responding after 30 minutes Pin
sujithkumarsl3-Oct-12 5:36
membersujithkumarsl3-Oct-12 5:36 
GeneralRe: C# Windows application not responding after 30 minutes Pin
sujithkumarsl3-Oct-12 5:51
membersujithkumarsl3-Oct-12 5:51 
AnswerRe: C# Windows application not responding after 30 minutes Pin
DaveyM693-Oct-12 5:21
mentorDaveyM693-Oct-12 5:21 
GeneralRe: C# Windows application not responding after 30 minutes Pin
sujithkumarsl3-Oct-12 5:41
membersujithkumarsl3-Oct-12 5:41 
GeneralRe: C# Windows application not responding after 30 minutes Pin
DaveyM694-Oct-12 1:34
mentorDaveyM694-Oct-12 1:34 
GeneralRe: C# Windows application not responding after 30 minutes Pin
sujithkumarsl4-Oct-12 11:17
membersujithkumarsl4-Oct-12 11:17 
QuestionTextbox validation c# help Pin
Robbie Kleman2-Oct-12 9:57
memberRobbie Kleman2-Oct-12 9:57 
Hi, so I have multiple textboxes on my c# winform and I am looking for a method to validate each box.

My current implementation works, however I am trying to find a way to expand on it and report which textboxes are not validating successfully.

So say return a string or array where i can search through and then set an errorprovider on them.

This is my validation method.(The method is void and not a bool because i want to return a variable with the failed textboxes)
        public bool Successful { get; set; }
        public string Information { get; set; }
 
        public void ValidateText(List<object> textbox)
        {
            foreach (object obj in textbox)
            {
                if (obj == "")
                {
                    Successful = false;
                }
                else
                {
                    Successful = true;
                }
            }
 
        }

and here is my main code
//list
            List<object> textbox = new List<object>();
            textbox.Add(FirstNTxt.Text);
            textbox.Add(LastNTxt.Text);
            textbox.Add(CourseTxt.Text);
            //validation
            FormValidation validate = new FormValidation();
            validate.ValidateText(textbox);
            if(!validate.Successful)
            {
                MessageBox.Show("error");
            }
            else
            {
               //more stuff that i did not paste in.
            }

Any assistance will be appreciated, thanks.
AnswerRe: Textbox validation c# help Pin
Matt T Heffron2-Oct-12 11:38
memberMatt T Heffron2-Oct-12 11:38 
AnswerRe: Textbox validation c# help Pin
Smart Arab2-Oct-12 12:17
memberSmart Arab2-Oct-12 12:17 
GeneralRe: Textbox validation c# help Pin
Robbie Kleman2-Oct-12 12:27
memberRobbie Kleman2-Oct-12 12:27 
GeneralRe: Textbox validation c# help Pin
Robbie Kleman8-Oct-12 4:37
memberRobbie Kleman8-Oct-12 4:37 
QuestionMonitoring file changes and changing data within the file... Pin
JD862-Oct-12 9:31
memberJD862-Oct-12 9:31 
AnswerRe: Monitoring file changes and changing data within the file... Pin
Smart Arab2-Oct-12 12:22
memberSmart Arab2-Oct-12 12:22 
GeneralRe: Monitoring file changes and changing data within the file... Pin
Pete O'Hanlon3-Oct-12 3:03
protectorPete O'Hanlon3-Oct-12 3:03 
AnswerRe: Monitoring file changes and changing data within the file... Pin
Eddy Vluggen3-Oct-12 2:39
memberEddy Vluggen3-Oct-12 2:39 
AnswerRe: Monitoring file changes and changing data within the file... Pin
Pete O'Hanlon3-Oct-12 3:26
protectorPete O'Hanlon3-Oct-12 3:26 
GeneralRe: Monitoring file changes and changing data within the file... Pin
Dave Kreskowiak3-Oct-12 6:33
mvpDave Kreskowiak3-Oct-12 6:33 
GeneralRe: Monitoring file changes and changing data within the file... Pin
Pete O'Hanlon3-Oct-12 6:37
protectorPete O'Hanlon3-Oct-12 6:37 
GeneralRe: Monitoring file changes and changing data within the file... Pin
Dave Kreskowiak3-Oct-12 14:38
mvpDave Kreskowiak3-Oct-12 14:38 
AnswerRe: Monitoring file changes and changing data within the file... Pin
BobJanova3-Oct-12 3:42
memberBobJanova3-Oct-12 3:42 
GeneralRe: Monitoring file changes and changing data within the file... Pin
Pete O'Hanlon3-Oct-12 4:10
protectorPete O'Hanlon3-Oct-12 4:10 
GeneralRe: Monitoring file changes and changing data within the file... Pin
JD863-Oct-12 14:59
memberJD863-Oct-12 14:59 
GeneralRe: Monitoring file changes and changing data within the file... Pin
JD8612-Oct-12 6:27
memberJD8612-Oct-12 6:27 
QuestionC# setup and deploy project templates located at? Pin
dcof2-Oct-12 6:10
memberdcof2-Oct-12 6:10 
AnswerRe: C# setup and deploy project templates located at? Pin
isenthil2-Oct-12 7:30
memberisenthil2-Oct-12 7:30 
GeneralRe: C# setup and deploy project templates located at? Pin
dcof2-Oct-12 18:48
memberdcof2-Oct-12 18:48 
GeneralRe: C# setup and deploy project templates located at? Pin
Dave Kreskowiak3-Oct-12 3:28
mvpDave Kreskowiak3-Oct-12 3:28 
AnswerRe: C# setup and deploy project templates located at? Pin
Dave Kreskowiak2-Oct-12 13:33
mvpDave Kreskowiak2-Oct-12 13:33 
Questionsyntax Pin
messages2-Oct-12 5:29
membermessages2-Oct-12 5:29 
AnswerRe: syntax Pin
Eddy Vluggen2-Oct-12 5:31
memberEddy Vluggen2-Oct-12 5:31 
GeneralRe: syntax Pin
messages2-Oct-12 6:28
membermessages2-Oct-12 6:28 
AnswerRe: syntax Pin
Richard MacCutchan2-Oct-12 6:54
mvpRichard MacCutchan2-Oct-12 6:54 
GeneralRe: syntax Pin
messages2-Oct-12 7:09
membermessages2-Oct-12 7:09 
Questionmultiple loading of assemblies - does it have any associated problems? Pin
Dan_K2-Oct-12 3:53
memberDan_K2-Oct-12 3:53 
AnswerRe: multiple loading of assemblies - does it have any associated problems? Pin
Eddy Vluggen2-Oct-12 4:23
memberEddy Vluggen2-Oct-12 4:23 
GeneralRe: multiple loading of assemblies - does it have any associated problems? Pin
Dan_K2-Oct-12 4:29
memberDan_K2-Oct-12 4:29 
AnswerRe: multiple loading of assemblies - does it have any associated problems? Pin
Eddy Vluggen2-Oct-12 5:29
memberEddy Vluggen2-Oct-12 5:29 
AnswerRe: multiple loading of assemblies - does it have any associated problems? Pin
jschell2-Oct-12 9:42
memberjschell2-Oct-12 9:42 
AnswerRe: multiple loading of assemblies - does it have any associated problems? Pin
Dave Kreskowiak2-Oct-12 13:29
mvpDave Kreskowiak2-Oct-12 13:29 
SuggestionRe: multiple loading of assemblies - does it have any associated problems? Pin
Guirec Le Bars2-Oct-12 19:11
memberGuirec Le Bars2-Oct-12 19:11 
GeneralRe: multiple loading of assemblies - does it have any associated problems? Pin
jschell3-Oct-12 11:16
memberjschell3-Oct-12 11:16 
AnswerRe: multiple loading of assemblies - does it have any associated problems? Pin
BobJanova3-Oct-12 6:05
memberBobJanova3-Oct-12 6:05 
QuestionWhen to use .PerformClick() Pin
MAW301-Oct-12 16:07
memberMAW301-Oct-12 16:07 

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

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


Advertise | Privacy | Mobile
Web04 | 2.8.150428.2 | Last Updated 5 May 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid