VmsZTestMain.cpp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //---------------------------------------------------------------------------
  2. #include <vcl.h>
  3. #pragma hdrstop
  4. #include <tchar.h>
  5. #include "AppGlobalF.h"
  6. //---------------------------------------------------------------------------
  7. USEFORM("FrmTestSubF.cpp", FrmTestSub);
  8. USEFORM("FrmTestMainF.cpp", VmsTestMain);
  9. //---------------------------------------------------------------------------
  10. WINAPI _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int)
  11. {
  12. if (!ApplicationSingleRun("TVmsTestMain", "VMS Test ÇÁ·Î±×·¥")) {
  13. return 0;
  14. }
  15. try
  16. {
  17. ReportMemoryLeaksOnShutdown = true;
  18. Application->Initialize();
  19. Application->MainFormOnTaskBar = true;
  20. Application->Title = "VMS Test ÇÁ·Î±×·¥";
  21. Application->CreateForm(__classid(TVmsTestMain), &VmsTestMain);
  22. Application->Run();
  23. }
  24. catch (Exception &exception)
  25. {
  26. Application->ShowException(&exception);
  27. }
  28. catch (...)
  29. {
  30. try
  31. {
  32. throw Exception("");
  33. }
  34. catch (Exception &exception)
  35. {
  36. Application->ShowException(&exception);
  37. }
  38. }
  39. return 0;
  40. }
  41. //---------------------------------------------------------------------------