C# 로그인 화면 구현

Park Yeeun·2023년 6월 30일
0

📌 프론트

label, textbox, button을 이용하여 구현
useSystemPasswordChar : True
PasswordChar : *


💬 코드

private void SignInButton_Click(object sender, EventArgs e)
{
  string userId = id.Text;
  string userPassword = password.Text;

  if (userId.Equals("MyId") && userPassword.Equals("MyPassword"))
  {
  	MessageBox.Show("로그인 성공", "로그인");
  }
  else
  {
 	 MessageBox.Show("로그인 실패", "로그인");
  }
}

💻 실행결과

profile
새싹 개발자입니당 🌱

0개의 댓글