private void RejectDisplay(string Exename)
        {
            string[] str = new string[] { "TempoRegiHanbaiTouroku", "TempoRegiPoint", "TempoRegiRyousyuusyo",
                                          "TempoRegiTorihikiReceipt", "TempoRegiRyougaeNyuuryoku", "TempoRegiShiharaiNyuuryoku", "TempoRegiTsurisenJyunbi", "TempoRegiNyuukinTouroku" };

            foreach (var f in str)
            {
                if (Exename == f)
                {
                    try
                    {
                        if (Base_DL.iniEntity.IsDM_D30Used)
                        {
                            cdo.RemoveDisplay();
                        }
                        // Base_DL.Ini_Entity_CDP.CDO_DISPLAY.RemoveDisplay();
                    }
                    catch
                    {
                        MessageBox.Show("Reclick on HBT");
                    }
                    break;
                }
            }
        }
Exemplo n.º 2
0
 static void Console_CancelKeyPress(object sender, ConsoleCancelEventArgs e)
 {
     try
     {
         cdo.RemoveDisplay();
     }
     catch { }
 }
Exemplo n.º 3
0
        public static void Main(string[] args)
        {
            try
            {
                cdo = new CashDrawerOpen();
                //Console.CancelKeyPress += new ConsoleCancelEventHandler(Console_CancelKeyPress);
                //    Isset = args[0];
                var      f   = "";
                Login_BL lbl = new Login_BL();;
                if (lbl.ReadConfig())
                {
                    f = Base_DL.iniEntity.DefaultMessage;
                }
                else
                {
                    f = "No Message at that moment. . . . . . . . . . . . . . . . ";
                }

                // cdo.RemoveDisplay();
                long RD = 0;
                long SD = 0;
                while (true)
                {
                    // Login_BL lbl = new Login_BL();
                    if (lbl.Display_Service_Status() == "0")
                    {
                        if (RD == 0)
                        {
                            cdo.RemoveDisplay();
                        }
                        RD++;
                        SD = 0;
                    }
                    else
                    {
                        if (SD == 0)
                        {
                            cdo.SetDisplay(true, true, f);
                        }
                        SD++;
                        RD = 0;
                    }
                    Thread.Sleep(1500);
                }
                //
                // cdo.SetDisplay(false, false, "1233123","PPPPP","TTTTT");
                //Start();
                //   Console.CancelKeyPress += new ConsoleCancelEventHandler(Console_CancelKeyPress);
            }
            catch (Exception ex)
            { Console.WriteLine(ex.StackTrace + ex.Message); }
            Console.ReadLine();

            //Start();
        }