12345678910111213
private: System::Void button1_Click(System::Object * sender, System::EventArgs * e) { System::String * txtPassword = textBox1->Text; System::String * setPassword = "12345678"; if (txtPassword == setPassword) { label1->Text = "Correct"; } else { label1->Text = "Try again"; } }
(strcmp (txtPassword ,setPassword) == 0)
123
char* convertStringToCharArray(string str){ return (char*)str.c_str(); }
if (*txtPassword == *setPassword)