When I try to debug the code below I get the following error message:
"error C2061: syntax error : identifier 'intCounter'"
The error points to the line of code with the while keyword.
What am I doing wrong with this do...while loop structure?
[vba]
private: System::Void Form1_Load(System::Object^ sender, System::EventArgs^ e) {
Int16 intCounter = 0;
Int16 intArray[] = {1,2,3,4,5};
do
{
String^ strMsg = gcnew String(intArray[intCounter].ToString());
MessageBox::Show(strMsg);
}while intCounter < 5;
}
[/vba]