-1

I'm creating a login that saves data on a database.

How do I declare the Name entered to the string value as name so when I say .Show it returns the name I typed in?

private void btnLogIn_Click(object sender, EventArgs e)
{
    string input = Microsoft.VisualBasic.Interaction.InputBox("Prompt", "Title",Name, 0, 0);
    MessageBox.Show(Name);
}

1 Answers1

1

Easy as this:

Change

MessageBox.Show(Name);

to

MessageBox.Show(input);
cramopy
  • 3,459
  • 6
  • 28
  • 42