I have used access database?
C# windows form login form not detect capital and small letters ?
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
I have used access database?
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Mounnad MohamedRank #1,633 · 945 reputationPosted Feb 3, 2023, 3:47 AM EST
Could you specify your issue? I mean put the code, the error that you got so we can help you
Naimish MakwanaRank #324 · 7.7K reputationPosted Feb 3, 2023, 3:54 AM EST
Hello NURU,
You can modify the code to perform a case-insensitive comparison. Use the string method “ToLower()” or “ToUpper()” on both the input and the stored username and password values before comparing them.
Example:
string username = txtUsername.Text.ToLower(); string password = txtPassword.Text.ToLower(); if (username == "admin" && password == "password") { //successful } else { //failed }Thanks
Naimish