Пример #1
0
 //窗体加载
 private void MainForm_Load(object sender, EventArgs e)
 {
     Form.CheckForIllegalCrossThreadCalls = false;
     try
     {
         Config.Machine = Share.DESForm(ConfigurationManager.AppSettings["Machine"]);
         Config.acceptOrderInterfaceUrl = ConfigurationManager.AppSettings["acceptOrderInterfaceUrl"];
         Config.url       = ConfigurationManager.AppSettings["url"];
         Config.venderId  = ConfigurationManager.AppSettings["venderId"];
         Config.notifyUrl = ConfigurationManager.AppSettings["notifyUrl"];
         Config.md5Key    = Share.DESForm(ConfigurationManager.AppSettings["md5Key"]);
         webBrowserLogin.ScriptErrorsSuppressed = true;
         this.webBrowserLogin.Navigate(Config.url);
         View.write("程序初始化完成");
     }
     catch (Exception ex)
     {
         MessageBox.Show("检查到参数信息未设置或设置错误,请重新设置!");
         FormSet frm = new FormSet();
         frm.ShowDialog();
         MessageBox.Show("您重新设置了参数信息,重新打开软件使配置生效!");
         this.Close();
         return;
     }
 }
Пример #2
0
 //窗体加载
 private void MainForm_Load(object sender, EventArgs e)
 {
     Form.CheckForIllegalCrossThreadCalls = false;
     try
     {
         Config.Machine = Share.DESForm(ConfigurationManager.AppSettings["Machine"]);
         Config.acceptOrderInterfaceUrl = ConfigurationManager.AppSettings["acceptOrderInterfaceUrl"];
         Config.url = ConfigurationManager.AppSettings["url"];
         Config.venderId = ConfigurationManager.AppSettings["venderId"];
         Config.notifyUrl = ConfigurationManager.AppSettings["notifyUrl"];
         Config.md5Key = Share.DESForm(ConfigurationManager.AppSettings["md5Key"]);
         webBrowserLogin.ScriptErrorsSuppressed = true;
         this.webBrowserLogin.Navigate(Config.url);
         View.write("程序初始化完成");
     }
     catch (Exception ex)
     {
         MessageBox.Show("检查到参数信息未设置或设置错误,请重新设置!");
         FormSet frm = new FormSet();
         frm.ShowDialog();
         MessageBox.Show("您重新设置了参数信息,重新打开软件使配置生效!");
         this.Close();
         return;
     }
 }
Пример #3
0
 private void btnRegex_Click(object sender, EventArgs e)
 {
     FormSet frm = new FormSet();
     frm.ShowDialog();
     if (frm.DialogResult == DialogResult.OK)
     {
         MessageBox.Show("您重新设置了参数信息,重新打开软件使配置生效!");
         this.Close();
     }
 }
Пример #4
0
        private void btnRegex_Click(object sender, EventArgs e)
        {
            FormSet frm = new FormSet();

            frm.ShowDialog();
            if (frm.DialogResult == DialogResult.OK)
            {
                MessageBox.Show("您重新设置了参数信息,重新打开软件使配置生效!");
                this.Close();
            }
        }