Beispiel #1
0
        /// <summary>
        /// 2013-Sep-20
        /// [email protected]
        ///    dic.Clear();
        ///    dic.Add("AddRow", "");
        ///    dic.Add("iRow", "1");
        ///    dic.Add("ServiceBasedOn", "$Service");
        ///    dic.Add("AgeBasedOn", "$Age");
        ///    pFromToAge._StandardTable_DE(dic);
        /// </summary>
        /// <param name="dic"></param>
        public void _StandardTable_DE(MyDictionary dic)
        {
            string sFunctionName = "_StandardTable_DE";

            _gLib._Report(_PassFailStep.Step, "Function <" + sFunctionName + "> Starts:");

            _gLib._SetSyncUDWin("AddRow", this.wRetirementStudio.wAddRow.btnAddRow, dic["AddRow"], 0);


            int iRow = Convert.ToInt32(dic["iRow"]);


            _gLib._SetSyncUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "Click", 0, false, 40, 38);
            _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{End}{End}", 0, ModifierKeys.Control, false);


            if (dic["ServiceBasedOn"] != "")
            {
                _gLib._SetSyncUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "Click", 0, false, 40, 38);
                _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{End}", 0, ModifierKeys.Control, false);
                _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{Tab}{Tab}", 0, ModifierKeys.Shift, false);

                int iActual = _fp._ReturnSelectRowIndex(this.wRetirementStudio.wFPGrid.grid);
                if (iActual + 1 != iRow)
                {
                    _gLib._MsgBox("", "Fail to locate the assigned row, please set <ServiceBasedOn> as <" + dic["ServiceBasedOn"] + "> in line; " + iRow);
                }
                else
                {
                    _gLib._SetSyncUDWin("ServiceBasedOn", this.wRetirementStudio.wCommonCombo_FPGrid.cbo, dic["ServiceBasedOn"], 0);
                }
            }

            if (dic["AgeBasedOn"] != "")
            {
                _gLib._SetSyncUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "Click", 0, false, 40, 38);
                _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{End}", 0, ModifierKeys.Control, false);
                _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{Tab}", 0, ModifierKeys.Shift, false);

                int iActual = _fp._ReturnSelectRowIndex(this.wRetirementStudio.wFPGrid.grid);
                if (iActual + 1 != iRow)
                {
                    _gLib._MsgBox("", "Fail to locate the assigned row, please set <AgeBasedOn> as <" + dic["AgeBasedOn"] + "> in line; " + iRow);
                }
                else
                {
                    _gLib._SetSyncUDWin("AgeBasedOn", this.wRetirementStudio.wCommonCombo_FPGrid.cbo, dic["AgeBasedOn"], 0);
                }
            }
            if (dic["Comparison"] != "")
            {
                _gLib._SetSyncUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "Click", 0, false, 40, 38);
                _gLib._SendKeysUDWin("Standard Table", this.wRetirementStudio.wFPGrid.grid, "{End}", 0, ModifierKeys.Control, false);

                int iActual = _fp._ReturnSelectRowIndex(this.wRetirementStudio.wFPGrid.grid);
                if (iActual + 1 != iRow)
                {
                    _gLib._MsgBox("", "Fail to locate the assigned row, please set <Comparison> as <" + dic["Comparison"] + "> in line; " + iRow);
                }
                else
                {
                    _gLib._SetSyncUDWin("Comparison", this.wRetirementStudio.wCommonCombo_FPGrid.cbo, dic["Comparison"], 0);
                }
            }


            _gLib._Report(_PassFailStep.Step, "Function <" + sFunctionName + "> Ends:");
        }