Exemple #1
0
        private void tm_Tick(object sender, EventArgs e)
        {
            try
            {
                tm.Stop();

                if (Whcode == "")
                {
                    setWhcode();
                }

                clsXML cs = new clsXML();
                cs.setXML();
                int tt = getTime();

                if (yesterday == 0)
                {
                    if (sendYesterday())
                    {
                        yesterday = 0;
                    }
                }

                if (tt != 0)
                {
                    tm.Interval = tt * 60000;
                    autoSend();
                }
                else
                {
                    uplog(Whcode, "time = 0");
                }
            }
            catch (Exception ex)
            {
                uplog(Whcode, ex.Message);
            }
            finally
            {
                tm.Start();
            }
        }
Exemple #2
0
        public frmAutoPos()
        {
            InitializeComponent();
            //StrConn = "Data Source=(local)\\sqlexpress;Initial Catalog=CMD-FX;User ID=sa;password=0000";
            //StrConnSup = "Data Source=(local)\\sqlexpress;Initial Catalog=dbBeautycommsupport;User ID=sa;password=0000";
            //StrConn = "Data Source=BCISP.DYNDNS.info,1401;Initial Catalog=CMD-FX;User ID=sa;password=0000";
            //StrConnSup = "Data Source=BCISP.DYNDNS.info,1401;Initial Catalog=dbBeautycommsupport;User ID=sa;password=0000";

            //Whcode = "";
            //StrConn = "Data Source=.;Initial Catalog=CMD-FX;User ID=sa;password=1Q2w3e4r@";
            //StrConnSup = "Data Source=.;Initial Catalog=dbBeautycommsupport;User ID=sa;password=1Q2w3e4r@";

            //Whcode = "1006";

            clsXML cs = new clsXML();

            StrConn    = cs.getLocalStr();
            StrConnSup = cs.getSupStr();
            Whcode     = "";
            getText();
            yesterday = 0;
        }