forked from AlbertBall/railway-dot-exe
-
Notifications
You must be signed in to change notification settings - Fork 0
/
railway.cpp
44 lines (43 loc) · 1.78 KB
/
railway.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
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include <tchar.h>
//---------------------------------------------------------------------------
USEFORM("..\..\GitHub Current Version\railway-dot-exe\PerfLogUnit.cpp", PerfLogForm);
USEFORM("..\..\GitHub Current Version\railway-dot-exe\ActionsDueUnit.cpp", ActionsDueForm);
USEFORM("..\..\GitHub Current Version\railway-dot-exe\AboutUnit.cpp", AboutForm);
USEFORM("..\..\GitHub Current Version\railway-dot-exe\InterfaceUnit.cpp", Interface);
//---------------------------------------------------------------------------
int WINAPI _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int)
{
try
{
Application->Initialize();
Application->MainFormOnTaskBar = true;
Application->HelpFile = ".\\Help_Files\\Help.chm";
/*NB CreateForm() runs the form's constructor, so if another form is referenced in it that form must be created first,
e.g. Interface before AboutForm (although InterfaceUnit.cpp includes AboutUnit.h the constructor doesn't reference it). */
Application->CreateForm(__classid(TInterface), &Interface);
Application->CreateForm(__classid(TPerfLogForm), &PerfLogForm);
Application->CreateForm(__classid(TAboutForm), &AboutForm);
Application->CreateForm(__classid(TActionsDueForm), &ActionsDueForm);
Application->Run();
}
catch (Exception &exception)
{
Application->ShowException(&exception);
}
catch (...)
{
try
{
throw Exception("");
}
catch (Exception &exception)
{
Application->ShowException(&exception);
}
}
return(0);
}
//---------------------------------------------------------------------------