17f666c99e76aeea1f5189b255937123939a2d42.svn-base 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. using System;
  2. using System.Collections.Generic;
  3. //using System.Linq;
  4. using System.Windows.Forms;
  5. using System.Threading;
  6. namespace IControls_FireManager
  7. {
  8. static class Program
  9. {
  10. /// <summary>
  11. /// 해당 응용 프로그램의 주 진입점입니다.
  12. /// </summary>
  13. [STAThread]
  14. static void Main()
  15. {
  16. try
  17. {
  18. bool createdNew;
  19. Mutex dup = new Mutex(true, "IControls_EmergencyRepeater", out createdNew);
  20. // 프로그램 뮤텍스
  21. if (createdNew)
  22. {
  23. Application.EnableVisualStyles();
  24. Application.SetCompatibleTextRenderingDefault(false);
  25. Application.Run(new EmergencyRepeater());
  26. }
  27. else
  28. MessageBox.Show("이미 프로그램이 사용중입니다");
  29. }
  30. catch
  31. {
  32. ; // 프로세스가 강제로 종료될때 예외가 발생할 수 있다.
  33. }
  34. }
  35. }
  36. }