コード例 #1
0
ファイル: frm_JEM.cs プロジェクト: ubaidmughal/SAP
        private void InitiallizeForm()
        {
            //  dtHead = oForm.DataSources.DataTables.Item("dtHead");
            // dtHead.Rows.Add(1);

            dtPendingJEs.Columns.Add("V#");
            dtPendingJEs.Columns.Add("Date");
            dtPendingJEs.Columns.Add("Remarks");
            dtPendingJEs.Columns.Add("Month");
            dtPendingJEs.Columns.Add("Year");
            dtPendingJEs.Columns.Add("Posted");
            dtPendingJEs.Columns.Add("PostedJE");
            dtPendingJEs.Columns.Add("Canceled");
            dtPendingJEs.Columns.Add("CanceledJE");

            oForm.Freeze(true);
            mtJE   = oForm.Items.Item("mtJE").Specific;
            mtDet  = oForm.Items.Item("mtDet").Specific;
            dtDet  = oForm.DataSources.DataTables.Item("dtDet");
            dtHead = oForm.DataSources.DataTables.Item("dtHead");
            cbOr   = oForm.Items.Item("cbOr").Specific;
            IcbOr  = oForm.Items.Item("cbOr");
            cbOr.ValidValues.Add("All", "All");
            fillUserCb();

            oForm.DataSources.UserDataSources.Add("txDN", SAPbouiCOM.BoDataType.dt_LONG_NUMBER, 15); // Days of Month
            txDN  = oForm.Items.Item("txDN").Specific;
            ItxDN = oForm.Items.Item("txDN");
            txDN.DataBind.SetBound(true, "", "txDN");


            oForm.DataSources.UserDataSources.Add("txCJ", SAPbouiCOM.BoDataType.dt_LONG_NUMBER, 15); // Days of Month
            txCJ  = oForm.Items.Item("txCJ").Specific;
            itxCJ = oForm.Items.Item("txCJ");
            txCJ.DataBind.SetBound(true, "", "txCJ");


            oForm.DataSources.UserDataSources.Add("txPJ", SAPbouiCOM.BoDataType.dt_LONG_NUMBER, 15); // Days of Month
            txPJ  = oForm.Items.Item("txPJ").Specific;
            itxPJ = oForm.Items.Item("txPJ");
            txPJ.DataBind.SetBound(true, "", "txPJ");



            oForm.DataSources.UserDataSources.Add("txDD", SAPbouiCOM.BoDataType.dt_DATE); // Days of Month
            txDD  = oForm.Items.Item("txDD").Specific;
            ItxDD = oForm.Items.Item("txDD");
            txDD.DataBind.SetBound(true, "", "txDD");

            oForm.DataSources.UserDataSources.Add("txRem", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 50); // Days of Month
            txRem  = oForm.Items.Item("txRem").Specific;
            ItxRem = oForm.Items.Item("txRem");
            txRem.DataBind.SetBound(true, "", "txRem");

            oForm.DataSources.UserDataSources.Add("txRef1", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 30); // Days of Month
            txRef1  = oForm.Items.Item("txRef1").Specific;
            ItxRef1 = oForm.Items.Item("txRef1");
            txRef1.DataBind.SetBound(true, "", "txRef1");

            oForm.DataSources.UserDataSources.Add("txRef2", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 30);    // Days of Month
            txRef2  = oForm.Items.Item("txRef2").Specific;
            ItxRef2 = oForm.Items.Item("txRef2");
            txRef2.DataBind.SetBound(true, "", "txRef2");

            oForm.DataSources.UserDataSources.Add("txDS", SAPbouiCOM.BoDataType.dt_SUM);      // Days of Month
            txDS  = oForm.Items.Item("txDS").Specific;
            ItxDS = oForm.Items.Item("txDS");
            txDS.DataBind.SetBound(true, "", "txDS");


            oForm.DataSources.UserDataSources.Add("txCS", SAPbouiCOM.BoDataType.dt_SUM);      // Days of Month
            txCS  = oForm.Items.Item("txCS").Specific;
            ItxCS = oForm.Items.Item("txCS");
            txCS.DataBind.SetBound(true, "", "txCS");


            oForm.DataSources.UserDataSources.Add("chkPost", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 1); // Days of Month
            chkPost  = oForm.Items.Item("chkPost").Specific;
            IchkPost = oForm.Items.Item("chkPost");
            chkPost.DataBind.SetBound(true, "", "chkPost");

            oForm.DataSources.UserDataSources.Add("optPP", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 1); // Days of Month
            optPP  = oForm.Items.Item("optPP").Specific;
            ioptPP = oForm.Items.Item("optPP");
            optPP.DataBind.SetBound(true, "", "optPP");

            oForm.DataSources.UserDataSources.Add("optC", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 1); // Days of Month
            optC  = oForm.Items.Item("optC").Specific;
            ioptC = oForm.Items.Item("optC");
            optC.DataBind.SetBound(true, "", "optC");

            oForm.DataSources.UserDataSources.Add("optPC", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 1); // Days of Month
            optPC  = oForm.Items.Item("optPC").Specific;
            ioptPC = oForm.Items.Item("optPC");
            optPC.DataBind.SetBound(true, "", "optPC");

            optC.GroupWith("optPP");
            optPC.GroupWith("optPP");
            optPP.Selected = true;

            btPost = oForm.Items.Item("btPost").Specific;

            lnkBG    = oForm.Items.Item("lnkBG").Specific;
            IchkPost = oForm.Items.Item("lnkBG");
        }
コード例 #2
0
ファイル: frm_JEP.cs プロジェクト: ubaidmughal/SAP
        private void InitiallizeForm()
        {
            //  dtHead = oForm.DataSources.DataTables.Item("dtHead");
            // dtHead.Rows.Add(1);

            dtPendingJEs.Columns.Add("DocDate");
            dtPendingJEs.Columns.Add("DocNum");
            dtPendingJEs.Columns.Add("DocTotal");
            dtPendingJEs.Columns.Add("Originator");

            oForm.Freeze(true);
            mtJE   = oForm.Items.Item("mtJE").Specific;
            mtDet  = oForm.Items.Item("mtDet").Specific;
            dtDet  = oForm.DataSources.DataTables.Item("dtDet");
            dtHead = oForm.DataSources.DataTables.Item("dtHead");
            cbOr   = oForm.Items.Item("cbOr").Specific;
            IcbOr  = oForm.Items.Item("cbOr");
            cbOr.ValidValues.Add("All", "All");
            fillUserCb();

            oForm.DataSources.UserDataSources.Add("txDN", SAPbouiCOM.BoDataType.dt_LONG_NUMBER, 15); // Days of Month
            txDN  = oForm.Items.Item("txDN").Specific;
            ItxDN = oForm.Items.Item("txDN");
            txDN.DataBind.SetBound(true, "", "txDN");

            oForm.DataSources.UserDataSources.Add("txDD", SAPbouiCOM.BoDataType.dt_DATE); // Days of Month
            txDD  = oForm.Items.Item("txDD").Specific;
            ItxDD = oForm.Items.Item("txDD");
            txDD.DataBind.SetBound(true, "", "txDD");

            oForm.DataSources.UserDataSources.Add("txRem", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 100); // Days of Month
            txRem  = oForm.Items.Item("txRem").Specific;
            ItxRem = oForm.Items.Item("txRem");
            txRem.DataBind.SetBound(true, "", "txRem");

            oForm.DataSources.UserDataSources.Add("txRef1", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 100); // Days of Month
            txRef1  = oForm.Items.Item("txRef1").Specific;
            ItxRef1 = oForm.Items.Item("txRef1");
            txRef1.DataBind.SetBound(true, "", "txRef1");

            oForm.DataSources.UserDataSources.Add("txRef2", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 100);    // Days of Month
            txRef2  = oForm.Items.Item("txRef2").Specific;
            ItxRef2 = oForm.Items.Item("txRef2");
            txRef2.DataBind.SetBound(true, "", "txRef2");

            oForm.DataSources.UserDataSources.Add("txDS", SAPbouiCOM.BoDataType.dt_SUM);      // Days of Month
            txDS  = oForm.Items.Item("txDS").Specific;
            ItxDS = oForm.Items.Item("txDS");
            txDS.DataBind.SetBound(true, "", "txDS");


            oForm.DataSources.UserDataSources.Add("txCS", SAPbouiCOM.BoDataType.dt_SUM);      // Days of Month
            txCS  = oForm.Items.Item("txCS").Specific;
            ItxCS = oForm.Items.Item("txCS");
            txCS.DataBind.SetBound(true, "", "txCS");


            oForm.DataSources.UserDataSources.Add("chkPost", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 1); // Days of Month
            chkPost  = oForm.Items.Item("chkPost").Specific;
            IchkPost = oForm.Items.Item("chkPost");
            chkPost.DataBind.SetBound(true, "", "chkPost");


            lnkBG    = oForm.Items.Item("lnkBG").Specific;
            IchkPost = oForm.Items.Item("lnkBG");
        }
コード例 #3
0
ファイル: KIS_SO0320A_HRD.cs プロジェクト: wldyd0210/TEST
        public virtual bool ET_lnkCENTCD_BFItemPressed(ItemEvent pVal)
        {
            oForm = B1Connections.theAppl.Forms.Item(pVal.FormUID);
            oLinkedButton = ((SAPbouiCOM.LinkedButton)(oForm.Items.Item("lnkCENTCD").Specific));
            // ADD YOUR ACTION CODE HERE ...

            SO.SO_COMMON_HRD.KeyValue = FN.GetItemValue(ref oForm, "edtCENTCD");
            B1Connections.theAppl.ActivateMenuItem("KIS_SO0040A_HRD");
            return false;

            //return true;
        }
コード例 #4
0
ファイル: KIS_SO0320A_HRD.cs プロジェクト: wldyd0210/TEST
        private void ClearUnManagedObject()
        {
            if (oLinkedButton != null) { Marshal.ReleaseComObject(oLinkedButton); } oLinkedButton = null;
            if (oCheckBox != null) { Marshal.ReleaseComObject(oCheckBox); } oCheckBox = null;
            if (oRS != null) { Marshal.ReleaseComObject(oRS); } oRS = null;
            if (oDB_M != null) { Marshal.ReleaseComObject(oDB_M); } oDB_M = null;
            if (oDB_1 != null) { Marshal.ReleaseComObject(oDB_1); } oDB_1 = null;
            if (oMatrix != null) { Marshal.ReleaseComObject(oMatrix); } oMatrix = null;
            if (pMatrix != null) { Marshal.ReleaseComObject(pMatrix); } pMatrix = null;
            if (oComboBox != null) { Marshal.ReleaseComObject(oComboBox); } oComboBox = null;
            if (oUDS != null) { Marshal.ReleaseComObject(oUDS); } oUDS = null;
            if (oEditText != null) { Marshal.ReleaseComObject(oEditText); } oEditText = null;
            if (oButton != null) { Marshal.ReleaseComObject(oButton); } oButton = null;
            if (pForm != null) { Marshal.ReleaseComObject(pForm); } pForm = null;
            if (oForm != null) { Marshal.ReleaseComObject(oForm); } oForm = null;

            //ADD YOUR ACTION CODE HERE ...
            System.GC.Collect();
            System.GC.WaitForPendingFinalizers();
        }
コード例 #5
0
ファイル: KIS_SO0182A_HRD.cs プロジェクト: wldyd0210/TEST
        public virtual void ET_lnk_AFItemPressed(ItemEvent pVal)
        {
            oForm = B1Connections.theAppl.Forms.Item(pVal.FormUID);
            oLinkedButton = ((SAPbouiCOM.LinkedButton)(oForm.Items.Item("lnk").Specific));

            // ADD YOUR ACTION CODE HERE ...
            try
            {
                string edtBENTRY = FN.GetItemValue(ref oForm, "edtBENTRY");

                if (string.IsNullOrEmpty(edtBENTRY) == false)
                {
                    using (KIS_SO0181A_HRD oKIS_SO0181A_HRD = new KIS_SO0181A_HRD())
                    {
                        oKIS_SO0181A_HRD.Act0_SubFormInit(oForm.UniqueID, edtBENTRY);
                    }
                }
            }
            catch (Exception ex)
            {
                B1Connections.theAppl.StatusBar.SetText(ex.Message, BoMessageTime.bmt_Short, BoStatusBarMessageType.smt_Error);
            }
        }
コード例 #6
0
ファイル: KIS_SO0040A_HRD.cs プロジェクト: wldyd0210/TEST
        private void ClearUnManagedObject() 
        {
            if (oLinkedButton != null) { Marshal.ReleaseComObject(oLinkedButton); } oLinkedButton = null;
            if (oMatrix != null) { Marshal.ReleaseComObject(oMatrix); } oMatrix = null;
            if (oEditText != null) { Marshal.ReleaseComObject(oEditText); } oEditText = null;
            if (oButton != null) { Marshal.ReleaseComObject(oButton); } oButton = null;
            if (oComboBox != null) { Marshal.ReleaseComObject(oComboBox); } oComboBox = null;
            if ((oForm != null)) { Marshal.ReleaseComObject(oForm); } oForm = null;

            // ADD YOUR ACTION CODE HERE ...
            System.GC.Collect();
            System.GC.WaitForPendingFinalizers();
        }
コード例 #7
0
ファイル: KIS_SO0270F_HRD.cs プロジェクト: wldyd0210/TEST
        public virtual void ET_likHLDCODE_AFItemPressed(ItemEvent pVal)
        {
            oForm = B1Connections.theAppl.Forms.Item(pVal.FormUID);
            oLinkedButton = ((SAPbouiCOM.LinkedButton)(oForm.Items.Item("likHLDCODE").Specific));
            // ADD YOUR ACTION CODE HERE ...

            if (oForm.Items.Item("cboHLDCODE").Specific.value != "")
            {
                string HldCode = oForm.Items.Item("cboHLDCODE").Specific.Selected.Description;

                B1Connections.theAppl.OpenForm(BoFormObjectEnum.fo_HolidaysTable, "", "");
                B1Connections.theAppl.Forms.ActiveForm.Mode = BoFormMode.fm_FIND_MODE;
                B1Connections.theAppl.Forms.ActiveForm.Items.Item("4").Specific.value = HldCode;
                B1Connections.theAppl.Forms.ActiveForm.Items.Item("1").Click(BoCellClickType.ct_Regular);
            }

        }
コード例 #8
0
ファイル: frm_65211.cs プロジェクト: ubaidmughal/SAP
        private void createUI()
        {
            int oldpanLevel = oForm.PaneLevel;

            if (oldpanLevel == 2)
            {
                oForm.PaneLevel = 1;
            }
            oForm.Freeze(true);



            SAPbouiCOM.Item   oItem;
            SAPbouiCOM.Item   oItem1;
            SAPbouiCOM.Folder oFolder;
            SAPbouiCOM.Item   oItemRef = oForm.Items.Item("126");


            try
            {
                cflcardcode(ocflCard, "ocflCard");


                // add Routing Matrix

                oItem           = oForm.Items.Add("lblCost", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top       = oItemRef.Top + 30;
                oItem.Height    = oItemRef.Height;
                oItem.Left      = oItemRef.Left;
                oItem.Width     = oItemRef.Width;
                oItem.FromPane  = 2;
                oItem.ToPane    = 2;
                oItem.TextStyle = 4;

                Program.objHrmsUI.loadSettings();
                oItem.LinkTo    = oItemRef.UniqueID;
                lblCost         = (SAPbouiCOM.StaticText)oItem.Specific;
                lblCost.Caption = "Cost Posting";


                oItem           = oForm.Items.Add("lblCard", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top       = oItemRef.Top + 50;
                oItem.Height    = oItemRef.Height;
                oItem.Left      = oItemRef.Left;
                oItem.Width     = oItemRef.Width;
                oItem.FromPane  = 2;
                oItem.ToPane    = 2;
                oItem.Visible   = false;
                oItem.LinkTo    = oItemRef.UniqueID;
                lblCard         = (SAPbouiCOM.StaticText)oItem.Specific;
                lblCard.Caption = "Supplier";


                oItem          = oForm.Items.Add("txSupplier", SAPbouiCOM.BoFormItemTypes.it_EDIT);
                oItem.Top      = oItemRef.Top + 50;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width;
                oItem.Width    = 150;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.LinkTo   = "lblCard";
                txSupplier     = (SAPbouiCOM.EditText)oItem.Specific;

                oForm.DataSources.UserDataSources.Add("txSupplier", SAPbouiCOM.BoDataType.dt_SHORT_TEXT);
                txSupplier.DataBind.SetBound(true, "", "txSupplier");


                txSupplier.ChooseFromListUID   = ocflCard.UniqueID;
                txSupplier.ChooseFromListAlias = "CardCode";
                oItem.Visible = false;

                txSupplier.ChooseFromListUID   = ocflCard.UniqueID;
                txSupplier.ChooseFromListAlias = "CardCode";



                oItem          = oForm.Items.Add("lnkCard", SAPbouiCOM.BoFormItemTypes.it_LINKED_BUTTON);
                oItem.Top      = oItemRef.Top + 50;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width - 20;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.LinkTo   = "txSupplier";
                SAPbouiCOM.LinkedButton lnkCard = (SAPbouiCOM.LinkedButton)oItem.Specific;
                lnkCard.LinkedObject     = BoLinkedObject.lf_BusinessPartner;
                lnkCard.LinkedObjectType = "2";



                oItemRef = lblCard.Item;

                oItem          = oForm.Items.Add("lblRef", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left;
                oItem.Width    = oItemRef.Width;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                lblRef         = (SAPbouiCOM.StaticText)oItem.Specific;
                lblRef.Caption = "Ref #";


                oItem          = oForm.Items.Add("txRef", SAPbouiCOM.BoFormItemTypes.it_EDIT);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width;
                oItem.Width    = 150;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                txRef          = (SAPbouiCOM.EditText)oItem.Specific;
                oForm.DataSources.UserDataSources.Add("txRef", SAPbouiCOM.BoDataType.dt_SHORT_TEXT);
                txRef.DataBind.SetBound(true, "", "txRef");


                oItemRef = lblRef.Item;

                oItem          = oForm.Items.Add("lblPD", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left;
                oItem.Width    = oItemRef.Width;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                lblPD          = (SAPbouiCOM.StaticText)oItem.Specific;
                lblPD.Caption  = "Posting Date";


                oItem          = oForm.Items.Add("txPD", SAPbouiCOM.BoFormItemTypes.it_EDIT);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width;
                oItem.Width    = 150;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                txPostingDate  = (SAPbouiCOM.EditText)oItem.Specific;

                oForm.DataSources.UserDataSources.Add("txPD", SAPbouiCOM.BoDataType.dt_DATE);
                txPostingDate.DataBind.SetBound(true, "", "txPD");

                oItemRef = lblPD.Item;

                oItem          = oForm.Items.Add("lblEA", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left;
                oItem.Width    = oItemRef.Width;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                lblEA          = (SAPbouiCOM.StaticText)oItem.Specific;
                lblEA.Caption  = "Expense Account";


                oItem          = oForm.Items.Add("txEA", SAPbouiCOM.BoFormItemTypes.it_EDIT);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width;
                oItem.Width    = 150;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                txEA           = (SAPbouiCOM.EditText)oItem.Specific;

                oForm.DataSources.UserDataSources.Add("txEA", SAPbouiCOM.BoDataType.dt_SHORT_TEXT);
                txEA.DataBind.SetBound(true, "", "txEA");
                txEA.Value = Program.objHrmsUI.getSetting("DfltExp");


                oItemRef = lblEA.Item;

                oItem              = oForm.Items.Add("lblPE", SAPbouiCOM.BoFormItemTypes.it_STATIC);
                oItem.Top          = oItemRef.Top + 18;
                oItem.Height       = oItemRef.Height;
                oItem.Left         = oItemRef.Left;
                oItem.Width        = oItemRef.Width;
                oItem.FromPane     = 2;
                oItem.ToPane       = 2;
                oItem.Visible      = false;
                oItem.LinkTo       = oItemRef.UniqueID;
                lblPE              = (SAPbouiCOM.StaticText)oItem.Specific;
                lblPE.Caption      = "Posted AP";
                lblPE.Item.Visible = false;

                oItem          = oForm.Items.Add("txPE", SAPbouiCOM.BoFormItemTypes.it_EDIT);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width;
                oItem.Enabled  = false;
                oItem.Width    = 150;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.Visible  = false;
                oItem.LinkTo   = oItemRef.UniqueID;
                txPE           = (SAPbouiCOM.EditText)oItem.Specific;
                oForm.DataSources.UserDataSources.Add("txPE", SAPbouiCOM.BoDataType.dt_SHORT_TEXT);
                txPE.DataBind.SetBound(true, "", "txPE");



                oItem          = oForm.Items.Add("lnkPE", SAPbouiCOM.BoFormItemTypes.it_LINKED_BUTTON);
                oItem.Top      = oItemRef.Top + 18;
                oItem.Height   = oItemRef.Height;
                oItem.Left     = oItemRef.Left + oItemRef.Width - 20;
                oItem.FromPane = 2;
                oItem.ToPane   = 2;
                oItem.LinkTo   = "txPE";
                SAPbouiCOM.LinkedButton lnkPE = (SAPbouiCOM.LinkedButton)oItem.Specific;
                lnkPE.LinkedObject     = BoLinkedObject.lf_PurchaseInvoice;
                lnkPE.LinkedObjectType = "18";



                oItemRef = txPE.Item;


                oItem               = oForm.Items.Add("btPost", SAPbouiCOM.BoFormItemTypes.it_BUTTON);
                oItem.Top           = oItemRef.Top + 18;
                oItem.Height        = oItemRef.Height + 5;
                oItem.Left          = oItemRef.Left;
                oItem.Enabled       = true;
                oItem.Width         = 150;
                oItem.FromPane      = 2;
                oItem.ToPane        = 2;
                oItem.LinkTo        = oItemRef.UniqueID;
                btPost              = (SAPbouiCOM.Button)oItem.Specific;
                btPost.Caption      = "Post AP";
                btPost.Item.Visible = false;

                txPE.Item.Enabled = false;
            }
            catch (Exception ex)
            {
                string message = ex.Message;
            }

            oForm.Freeze(false);
            txPE.Item.Enabled = false;
            oForm.PaneLevel   = oldpanLevel;
        }
コード例 #9
0
ファイル: KIS_SD0050A_HRD.cs プロジェクト: wldyd0210/TEST
        public virtual void ET_lnkBPENTRY_AFItemPressed(ItemEvent pVal) {
            oForm = B1Connections.theAppl.Forms.Item(pVal.FormUID);
            oLinkedButton = ((SAPbouiCOM.LinkedButton)(oForm.Items.Item("lnkBPENTRY").Specific));
            // ADD YOUR ACTION CODE HERE ...
            //이미등록된 내역여부를 확인 후, 있으면 불러오기 없으면 선수금리스트 조회
            SAPbouiCOM.DBDataSource oKIS_SD0050T_HRD = oForm.DataSources.DBDataSources.Item("@KIS_SD0050T_HRD");

            try
            {




                string DocEntry = oKIS_SD0050T_HRD.GetValue("U_BPENTRY", 0).Trim();

                //선수금 내역이 이미 등록되어있는가?
                if (string.IsNullOrEmpty(DocEntry) == false)
                {
                    this.LoadSubForm(oForm, "KIS_SD0070_HRD", DocEntry);
                }

            }
            catch (Exception ex)
            {
                B1Connections.theAppl.StatusBar.SetText(ex.Message, BoMessageTime.bmt_Short, BoStatusBarMessageType.smt_Error);
            }
            finally
            {
                oKIS_SD0050T_HRD = null;
            }
        }