Ejemplo n.º 1
0
 private void btRun_Click(object sender, EventArgs e)
 {
     //运行前检查WatchConfig.xml中需要的数据是否已经配置齐全
     if (ClickBeforeCheck())
     {
         string coinfigName = string.Empty;
         if (rdoWorkShop.Checked)
         {
             coinfigName = this.ucWorkshop.SelectedItemValue.ToString().ToUpper();
         }
         if (rdoSSPanel.Checked)
         {
             coinfigName = this.ucWorkShopBySSCode.SelectedItemValue.ToString().ToUpper() + "_" + this.ucProductLine.SelectedItemValue.ToString().ToUpper();
         }
         if (HasBeenConfigured(coinfigName))
         {
             FFacWatchPanelNew watchPanel = null;
             if (this.rdoSSPanel.Checked)
             {
                 watchPanel = new FFacWatchPanelNew(this.ucWorkShopBySSCode.SelectedItemValue.ToString().ToUpper(), this.ucProductLine.SelectedItemValue.ToString().ToUpper(), WatchPanelType.ProductLine, coinfigName);
             }
             if (this.rdoWorkShop.Checked)
             {
                 watchPanel = new FFacWatchPanelNew(this.ucWorkshop.SelectedItemValue.ToString().ToUpper(), string.Empty, WatchPanelType.WorkShop, coinfigName);
             }
             watchPanel.Owner = this;
             watchPanel.ShowDialog(this);
         }
     }
 }
Ejemplo n.º 2
0
        private void btOK_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrEmpty(this.DrpConfigList.SelectedItemValue.ToString()))
            {
                this.DrpConfigList.Focus();
                return;
            }

            if (!CheckConfig())
            {
                return;
            }

            FFacWatchPanelNew main = new FFacWatchPanelNew(this.DrpConfigList.SelectedItemValue.ToString(), string.Empty);

            main.Owner = this;
            main.ShowDialog(this);
        }