-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathForm1.cpp
47 lines (39 loc) · 1.06 KB
/
Form1.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#include "stdafx.h"
#include <string>
#include <vector>
#include <set>
//#include "options.h"
#include "Form1.h"
#include <windows.h>
[STAThreadAttribute]
int main(cli::array<System::String ^> ^args)
{
if ( args->Length == 0 )
{
// Aktivieren visueller Effekte von Windows XP, bevor Steuerelemente erstellt werden
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
// Hauptfenster erstellen und ausführen
Application::Run(gcnew Form1( args ));
}
else
{
AttachConsole( ATTACH_PARENT_PROCESS );
gcnew Form1( args );
}
return 0;
}
/*
int APIENTRY _tWinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPTSTR lpCmdLine,
int nCmdShow)
{
System::String ^ schemaFolder;
// schemaFolder = lpCmdLine;
System::Threading::Thread::CurrentThread->ApartmentState = System::Threading::ApartmentState::STA;
Form1 ^ myForm = gcnew Form1( schemaFolder );
Application::Run( myForm );
return 0;
}
*/