Error i can't fix

I'm working on a store management program, and i created a Windows Form for verifying login details of a user. Then in a seperate header file i created this function.

I'm getting these errors on textBox1 and textBox2.
a nonstatic member reference must be relative to a specific object
error C2227: left of '->Text' must point to class/struct/union/generic type


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
	bool verify()
	{
		Verify ^form2 = gcnew Verify();
		form2->ShowDialog();

		string user = Stos(Verify::textBox1->Text);
		string pass = Stos(Verify::textBox2->Text);
		if( signIn(user,pass) )
		{
			return true;
		}
		else
		{
			return false;
		}
	}
show the code for textBox1/2
Topic archived. No new replies allowed.