Click here to Skip to main content
15,885,365 members
Home / Discussions / C#
   

C#

 
AnswerRe: C# List of Tasks Pin
lmoelleb7-Apr-23 1:54
lmoelleb7-Apr-23 1:54 
AnswerRe: C# List of Tasks Pin
jschell7-Apr-23 9:20
jschell7-Apr-23 9:20 
AnswerRe: C# List of Tasks Pin
Richard Deeming10-Apr-23 21:27
mveRichard Deeming10-Apr-23 21:27 
QuestionPassword Regex Help Pin
Jassim Rahma28-Mar-23 9:41
Jassim Rahma28-Mar-23 9:41 
AnswerRe: Password Regex Help Pin
Dave Kreskowiak28-Mar-23 11:21
mveDave Kreskowiak28-Mar-23 11:21 
AnswerRe: Password Regex Help Pin
OriginalGriff28-Mar-23 19:55
mveOriginalGriff28-Mar-23 19:55 
AnswerRe: Password Regex Help Pin
Eddy Vluggen1-Apr-23 6:31
professionalEddy Vluggen1-Apr-23 6:31 
AnswerRe: Password Regex Help Pin
Member 115612953-Apr-23 23:50
Member 115612953-Apr-23 23:50 
probe the next function:

bool IsValidPassword(string password, 
            int minLength=10, 
            int maxLength=50, 
            bool requireLowercase=true, 
            bool requireUppercase=false, 
            bool requireNumber=false,
            bool requireSimbol=false)
        {
            if (string.IsNullOrEmpty(password))
            {
                return false;
            }
            if (password.Length < minLength || password.Length > maxLength)
            {
                return false;
            }
            if (requireUppercase && !Regex.IsMatch(password, "[A-Z]"))
            {
                return false;
            }
            if (requireLowercase && !Regex.IsMatch(password, "[a-z]"))
            {
                return false;
            }
            if (requireNumber && !Regex.IsMatch(password, "[0-9]"))
            {
                return false;
            }
            string pattern= @"[!@#$%^&*()_+\-=\[\]{};':" + "\"" + @"\\|,.<>\/? ~]";
            if (requireSimbol && !Regex.IsMatch(password, pattern))
                return false;
            return true;
        }

QuestionRe: Password Regex Help Pin
Eddy Vluggen14-Apr-23 6:41
professionalEddy Vluggen14-Apr-23 6:41 
AnswerRe: Password Regex Help Pin
Ravi Bhavnani15-Apr-23 10:52
professionalRavi Bhavnani15-Apr-23 10:52 
AnswerRe: Password Regex Help Pin
Bohdan Stupak19-Apr-23 3:28
professionalBohdan Stupak19-Apr-23 3:28 
Questioncreate our own unit testing framework in C# Pin
Sakhalean26-Mar-23 18:32
Sakhalean26-Mar-23 18:32 
AnswerRe: create our own unit testing framework in C# Pin
OriginalGriff26-Mar-23 21:00
mveOriginalGriff26-Mar-23 21:00 
AnswerRe: create our own unit testing framework in C# Pin
jschell27-Mar-23 7:00
jschell27-Mar-23 7:00 
AnswerRe: create our own unit testing framework in C# Pin
Gerry Schmitz27-Mar-23 11:39
mveGerry Schmitz27-Mar-23 11:39 
GeneralRe: create our own unit testing framework in C# Pin
mtoha13-Apr-23 16:39
professionalmtoha13-Apr-23 16:39 
QuestionManagement of window coordinates and sizes for multiple screens of different resolutions Pin
temuco25-Mar-23 13:14
professionaltemuco25-Mar-23 13:14 
AnswerRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
OriginalGriff25-Mar-23 20:18
mveOriginalGriff25-Mar-23 20:18 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
temuco26-Mar-23 1:22
professionaltemuco26-Mar-23 1:22 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
Dave Kreskowiak26-Mar-23 5:38
mveDave Kreskowiak26-Mar-23 5:38 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
temuco26-Mar-23 22:28
professionaltemuco26-Mar-23 22:28 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
Dave Kreskowiak27-Mar-23 1:30
mveDave Kreskowiak27-Mar-23 1:30 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
temuco27-Mar-23 21:18
professionaltemuco27-Mar-23 21:18 
GeneralRe: Management of window coordinates and sizes for multiple screens of different resolutions Pin
Gerry Schmitz26-Mar-23 7:57
mveGerry Schmitz26-Mar-23 7:57 
QuestionEntity Framework Code First - two Foreign Keys from same table Pin
Alex Dunlop21-Mar-23 8:43
Alex Dunlop21-Mar-23 8:43 

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.