Esempio n. 1
0
        private void YuanTuoForm_FormClosing(object sender, FormClosingEventArgs e)
        {
            GlobalTools.yuantuoForm = null;

            SystemDefine.ShowTaskTools();
            SkypeHelper.CloseSkype();
        }
Esempio n. 2
0
        private static void ReadIdCard(IDCard idcard)
        {
            string path = Application.StartupPath + "//success.wav";

            SystemDefine.PlaySound(path, 0, SystemDefine.SND_ASYNC | SystemDefine.SND_FILENAME);//播放音乐
            SendKeys.SendWait(idcard.IDC.ToUpper());
            IDCardConfig config = StaticCacheManager.GetConfig <IDCardConfig>();

            if (config.AddReturn)
            {
                SendKeys.SendWait("{ENTER}");
            }
        }
Esempio n. 3
0
        private void timerTopFirst_Tick(object sender, EventArgs e)
        {
            this.timerTopFirst.Stop();
#if DEBUG
            Console.WriteLine(System.DateTime.Now.ToShortTimeString() + "定时检测拨号窗体是否存在,结果为:" + GlobalTools.skypeForm);
#endif
            if (GlobalTools.skypeForm == null)
            {
                this.BringToFront();
                SystemDefine.SetWindowTop(this.Handle);
            }
            this.timerTopFirst.Start();
        }
Esempio n. 4
0
        private void YuanTuoForm_Load(object sender, EventArgs e)
        {
            string width  = System.Configuration.ConfigurationSettings.AppSettings["width"];
            string height = System.Configuration.ConfigurationSettings.AppSettings["height"];

            this.Size     = new Size(Int32.Parse(width), Int32.Parse(height));
            this.Location = new Point(0, 0);
            urlHome       = System.Configuration.ConfigurationSettings.AppSettings["configUrl"];
            domainPrefix  = urlHome;
            // nowUrl.in
            domainPrefix   = domainPrefix.Substring(domainPrefix.IndexOf(":") + 3);//http://之后的
            domainPrefix   = domainPrefix.Substring(0, domainPrefix.IndexOf('/'));
            domainPrefix   = "http://" + domainPrefix;
            locationPrefix = System.Configuration.ConfigurationSettings.AppSettings["locationPrefix"];
            this.webBrowser1.ScriptErrorsSuppressed = true;
            this.AutoScroll = false;
            int unoperationTime = Convert.ToInt32(System.Configuration.ConfigurationSettings.AppSettings["unoperationTime"]) * 1000;

            this.timer1.Interval = unoperationTime;
            this.timer1.Start();
            this.NavigateHome();
            SystemDefine.HideTaskTools();
            try
            {
                SkypeHelper.StartSkype();
            }
            catch
            {
                MessageBox.Show("Skype未能正常启动!!");
            }
            GlobalTools.yuantuoForm = this;
            HideHint();
            string topfirstTimer = System.Configuration.ConfigurationSettings.AppSettings["TopFirstTimer"];

            if (topfirstTimer == "true")
            {
                this.timerTopFirst.Start();
            }
            // this.webBrowser1.n
        }
Esempio n. 5
0
 public YuanTuoForm()
 {
     InitializeComponent();
     SystemDefine.ShowTaskTools();
 }