Created
October 24, 2016 13:27
-
-
Save csprofile/ff852024189fcbc9df28540413130110 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| static class Program | |
| { | |
| /// <summary> | |
| /// The main entry point for the application. | |
| /// </summary> | |
| static void Main() | |
| { | |
| #if (!DEBUG) //Release | |
| ServiceBase[] ServicesToRun; | |
| ServicesToRun = new ServiceBase[] | |
| { | |
| new serviceClassName() | |
| }; | |
| ServiceBase.Run(ServicesToRun); | |
| #else | |
| serviceClassName serviceClassName = new serviceClassName(); | |
| serviceClassName.StartApp(); | |
| System.Threading.Thread.Sleep(System.Threading.Timeout.Infinite); | |
| #endif | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment