how can made login user form application in c#.net?
-
salam sir; how can made login user form application in c#.net?please help me. thanks sir
mohammedali
-
salam sir; how can made login user form application in c#.net?please help me. thanks sir
mohammedali
An example of the code to check the entered credentials could be:
private void buttonLogin_Click(object sender, EventArgs e)
{
if (txtPassword.Text == "abc123" && txtUsername.Text == "admin")
{
MessageBox.Show("You are now logged in!");
// ...
}
else
{
MessageBox.Show("Wrong password or username!");
}
}The rest is up to you.
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
-
An example of the code to check the entered credentials could be:
private void buttonLogin_Click(object sender, EventArgs e)
{
if (txtPassword.Text == "abc123" && txtUsername.Text == "admin")
{
MessageBox.Show("You are now logged in!");
// ...
}
else
{
MessageBox.Show("Wrong password or username!");
}
}The rest is up to you.
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
Please tell me you didn't post this with all sincerity??
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007 -
Please tell me you didn't post this with all sincerity??
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007What do you mean by that? I don't get it. (I'm Danish.)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
-
What do you mean by that? I don't get it. (I'm Danish.)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
Oh God, you were serious. :omg:
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007 -
Oh God, you were serious. :omg:
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007 -
:laugh::laugh::laugh::laugh: You know what?? Sometimes I find this forum funnier than the lounge:-D
Smile: A curve that can set a lot of things straight! (\ /) (O.o) (><)
Allright, that's it. Is it the source code you are laughing at? As far as I can see the code is okay. Please let me know ;)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
-
Allright, that's it. Is it the source code you are laughing at? As far as I can see the code is okay. Please let me know ;)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
Hey there:) No, the code logic looks just fine to me, I think he means something else like you're giving the guy the password to set so you can hack him, some sort of a joke you know.. the way he was attaching you was the funny part:laugh:
Smile: A curve that can set a lot of things straight! (\ /) (O.o) (><)
-
Hey there:) No, the code logic looks just fine to me, I think he means something else like you're giving the guy the password to set so you can hack him, some sort of a joke you know.. the way he was attaching you was the funny part:laugh:
Smile: A curve that can set a lot of things straight! (\ /) (O.o) (><)
Oh, I see :D But as I wrote in the end of my first post: The rest is up to you. What I meant by that, was that he should change the password and username ;) Hope everything is clear now :)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
-
Oh, I see :D But as I wrote in the end of my first post: The rest is up to you. What I meant by that, was that he should change the password and username ;) Hope everything is clear now :)
Virtual1ty -- "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
And keep it as a hard-coded username and password??? What would it take to change the password? Rewriting the app and compiling is not a viable option. What would it take to add additional users too?? How about revoking a user?? Rewriting the app again?? The code is useless, except for a demonstration of the
if
statement.A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007