|
Create a new project by default and automatically generate code in Project.cpp
In WINAPI WinMain (HINSTANCE, HINSTANCE, LPSTR, int)
{
try
{
Application-> Initialize ();
Application-> CreateForm (__ classid (TForm1),&Form1);
Application-> Run ();
}
catch (Exception&exception)
{
Application-> ShowException (&exception);
}
catch (...)
{
try
{
throw Exception ("");
}
catch (Exception&exception)
{
Application-> ShowException (&exception);
}
}
return 0;
}
This sentence Application-> CreateForm (__ classid (TForm1),&Form1);
Created Form1
If your project has more than one Form,
You can make other Forms not new, and new yourself in the code
Menu project-> Options-> Forms
Move the corresponding form from auto-create forms to available forms
Note that you cannot "drag" all forms to the right |
|