WaitForKeyPress() public static method

public static WaitForKeyPress ( ) : void
return void
Beispiel #1
0
        private static int Main(string[] args)
        {
            try {
                return(ConsoleCommandDispatcher.DispatchCommand(
                           GetCommands(), args, Console.Out));
            } catch (Exception ex) {
                Console.WriteLine(ex.Message);
                Console.WriteLine(ex.StackTrace);
                return(-1);
            } finally {
#if DEBUG
                if (Debugger.IsAttached)
                {
                    ConsoleQuestion.WaitForKeyPress();
                }
#endif
            }
        }
Beispiel #2
0
        private static int Main(string[] args)
        {
            //SqlServerTypes.Utilities.LoadNativeAssemblies(Microsoft.SqlServer.Server.MapPath("~"));
            //SqlServerTypes.Utilities.LoadNativeAssemblies(Server.MapPath("~/bin"));
            //SqlServerTypes.Utilities.LoadNativeAssemblies(AppDomain.CurrentDomain.BaseDirectory);
            try {
                return(ConsoleCommandDispatcher.DispatchCommand(
                           GetCommands(), args, Console.Out));
            } catch (Exception ex) {
                Console.WriteLine(ex.Message);
                Console.WriteLine(ex.StackTrace);
                return(-1);
            } finally {
#if DEBUG
                Console.WriteLine("Debug");
                if (Debugger.IsAttached)
                {
                    ConsoleQuestion.WaitForKeyPress();
                }
#endif
            }
        }