Ejemplo n.º 1
0
        private void LoadMobileAppData_Load(object sender, EventArgs e)
        {
            buttonOK.Enabled     = false;
            buttonCancel.Enabled = false;

            log         = new XLog();
            log.DirName = config.logpath;

            clBGPBmobile = new CBGPBmobileData(config);
            clUP         = new CBelWebData(config);
            clAssist     = new CAssistData(config);

            cr = 1;
            init_combo();

            if (config.reloadflag == 1)
            {
                checkBoxReload.Checked = true;
            }
            else
            {
                checkBoxReload.Checked = false;
            }

            if (config.moveflag == 1)
            {
                checkBoxMove.Checked = true;
            }
            else
            {
                checkBoxMove.Checked = false;
            }
        }
Ejemplo n.º 2
0
        private void BelWebViewData_Load(object sender, EventArgs e)
        {
            try
            {
                log         = new XLog();
                log.DirName = config.logpath;
                clWork      = new CBelWebData(config);

                OnPermit("MAIN");
            }
            catch (Exception ex) { MessageBox.Show(ex.TargetSite + " " + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Error); }
        }
Ejemplo n.º 3
0
        private void Execute()
        {
            string msg;
            int    retcode;

            try
            {
                if (oClass is CValidData)
                {
                    CValidData g_clBook = (CValidData)oClass;
                    //      List<STValidData> g_listResult;

                    //  oData =  g_clBook.GetData((STValidDataParam)oParam);
                    DataTable table;
                    g_clBook.GetTable((STValidDataParam)oParam, out table, out msg);

                    oData = table;
                    bOper = true;
                    timer1.Stop();
                    bClose       = false;
                    DialogResult = DialogResult.OK;
                }

                if (oClass is CBelWebData)
                {
                    DataTable   table;
                    CBelWebData g_clBook = (CBelWebData)oClass;
                    //      List<STValidData> g_listResult;

                    retcode = g_clBook.GetTable((STVPBelWebData)oParam, out table, out msg);

                    if (retcode == 0)
                    {
                        oData = table;
                    }
                    else
                    {
                        MessageBox.Show(msg, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }

                    bOper = true;
                    timer1.Stop();
                    bClose       = false;
                    DialogResult = DialogResult.OK;
                }

                if (oClass is CAssistData)
                {
                    DataTable   table;
                    CAssistData g_clBook = (CAssistData)oClass;
                    //      List<STValidData> g_listResult;

                    retcode = g_clBook.GetTable((STVPAssistData)oParam, out table, out msg);

                    if (retcode == 0)
                    {
                        oData = table;
                    }
                    else
                    {
                        MessageBox.Show(msg, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }

                    bOper = true;
                    timer1.Stop();
                    bClose       = false;
                    DialogResult = DialogResult.OK;
                }

                if (oClass is CRcpData)
                {
                    DataTable table;
                    CRcpData  g_clBook = (CRcpData)oClass;
                    //      List<STValidData> g_listResult;

                    retcode = g_clBook.GetTable((STVPRCPData)oParam, out table, out msg);

                    if (retcode == 0)
                    {
                        oData = table;
                    }
                    else
                    {
                        MessageBox.Show(msg, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    }

                    bOper = true;
                    timer1.Stop();
                    bClose       = false;
                    DialogResult = DialogResult.OK;
                }



                timer1.Stop();
                bClose       = false;
                DialogResult = DialogResult.OK;
            }
            catch (Exception ex) { MessageBox.Show(ex.Message, ex.Source); timer1.Stop(); }
        }