Exemple #1
0
        static void Main(string[] args)
        {
            if (args.Length < 6)
            {
                Console.WriteLine("Usage: NotecardTool [first] [last] [password] [put] [name] [notecard.txt] ");
                return;
            }

            if (!File.Exists(args[5]))
            {
                Console.WriteLine("Cannot find file: " + args[5]);
                return;
            }

            NotecardTool tool = new NotecardTool();

            tool.NotecardName = args[4] + " : " + Helpers.GetUnixTime();
            tool.FileName     = args[5];

            tool.Connect(args[0], args[1], args[2]);

            if (tool.ConnectedSignal.WaitOne(TimeSpan.FromMinutes(1), false))
            {
                tool.doStuff();
                tool.Disconnect();
            }
        }
        static new void Main(string[] args)
        {
            if (args.Length < 6)
            {
                Console.WriteLine("Usage: NotecardTool [first] [last] [password] [put] [name] [notecard.txt] ");
                return;
            }

            if (!File.Exists(args[5]))
            {
                Console.WriteLine("Cannot find file: " + args[5]);
                return;
            }

            NotecardTool tool = new NotecardTool();

            tool.NotecardName = args[4] + " : " + Helpers.GetUnixTime();
            tool.FileName     = args[5];

            tool.Connect(args[0], args[1], args[2]);
            tool.doStuff();
            tool.Disconnect();

            System.Threading.Thread.Sleep(500);
        }
        static new void Main(string[] args)
        {
            if (args.Length < 6)
            {
                Console.WriteLine("Usage: NotecardTool [first] [last] [password] [put] [name] [notecard.txt] ");
                return;
            }

            if( !File.Exists(args[5]) )
            {
                Console.WriteLine("Cannot find file: " + args[5]);
                return;
            }

            NotecardTool tool = new NotecardTool();
            tool.NotecardName = args[4] + " : " + Helpers.GetUnixTime();
            tool.FileName = args[5];

            tool.Connect(args[0], args[1], args[2]);
            tool.doStuff();
            tool.Disconnect();

            System.Threading.Thread.Sleep(500);
        }
        static void Main(string[] args)
        {
            if (args.Length < 6)
            {
                Console.WriteLine("Usage: NotecardTool [first] [last] [password] [put] [name] [notecard.txt] ");
                return;
            }

            if( !File.Exists(args[5]) )
            {
                Console.WriteLine("Cannot find file: " + args[5]);
                return;
            }

            NotecardTool tool = new NotecardTool();
            tool.NotecardName = args[4] + " : " + Helpers.GetUnixTime();
            tool.FileName = args[5];

            tool.Connect(args[0], args[1], args[2]);

            if (tool.ConnectedSignal.WaitOne(TimeSpan.FromMinutes(1), false))
            {
                tool.doStuff();
                tool.Disconnect();
            }
        }