Example #1
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.StaticText0              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.StaticText1              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.StaticText2              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_2").Specific));
     this.CheckBoxImpresion        = ((SAPbouiCOM.CheckBox)(this.GetItem("chkImp").Specific));
     this.StaticText3              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_4").Specific));
     this.EditTextDocDesde         = ((SAPbouiCOM.EditText)(this.GetItem("docDesde").Specific));
     this.StaticText4              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_6").Specific));
     this.EditTextDocHasta         = ((SAPbouiCOM.EditText)(this.GetItem("docHasta").Specific));
     this.CBoxTpoEstado            = ((SAPbouiCOM.ComboBox)(this.GetItem("tpoEstado").Specific));
     this.CBoxtpoRuta              = ((SAPbouiCOM.ComboBox)(this.GetItem("tpoRuta").Specific));
     this.CBoxtpoRuta.ClickBefore += new SAPbouiCOM._IComboBoxEvents_ClickBeforeEventHandler(this.CBoxtpoRuta_ClickBefore);
     this.StaticText5              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_10").Specific));
     this.StaticText6              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_11").Specific));
     this.EditTextFechaDesde       = ((SAPbouiCOM.EditText)(this.GetItem("FechaD").Specific));
     this.StaticText7              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_13").Specific));
     this.EditTextFechaHasta       = ((SAPbouiCOM.EditText)(this.GetItem("FechaH").Specific));
     this.oGrid = ((SAPbouiCOM.Grid)(this.GetItem("Grid").Specific));
     this.oGrid.LinkPressedBefore    += new SAPbouiCOM._IGridEvents_LinkPressedBeforeEventHandler(this.oGrid_LinkPressedBefore);
     this.oGrid.LinkPressedAfter     += new SAPbouiCOM._IGridEvents_LinkPressedAfterEventHandler(this.oGrid_LinkPressedAfter);
     this.oGrid.DoubleClickBefore    += new SAPbouiCOM._IGridEvents_DoubleClickBeforeEventHandler(this.oGrid_DoubleClickBefore);
     this.oGrid.DoubleClickAfter     += new SAPbouiCOM._IGridEvents_DoubleClickAfterEventHandler(this.oGrid_DoubleClickAfter);
     this.ButtonBuscar                = ((SAPbouiCOM.Button)(this.GetItem("bBuscar").Specific));
     this.ButtonBuscar.ClickBefore   += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.ButtonBuscar_ClickBefore);
     this.ButtonImprimir              = ((SAPbouiCOM.Button)(this.GetItem("bImprimir").Specific));
     this.ButtonImprimir.ClickAfter  += new SAPbouiCOM._IButtonEvents_ClickAfterEventHandler(this.ButtonImprimir_ClickAfter);
     this.ButtonImprimir.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.ButtonImprimir_ClickBefore);
     this.ButtonCancelar              = ((SAPbouiCOM.Button)(this.GetItem("bCancelar").Specific));
     this.ButtonCancelar.ClickAfter  += new SAPbouiCOM._IButtonEvents_ClickAfterEventHandler(this.ButtonCancelar_ClickAfter);
     this.ButtonCancelar.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.ButtonCancelar_ClickBefore);
     this.CheckBox1 = ((SAPbouiCOM.CheckBox)(this.GetItem("chk_sel").Specific));
     this.OnCustomInitialize();
 }
        public ChooseFromList()
        {
            AppHelper.SetApplication(ref this.oApplication);

            this.oForm = UIHelper.CriarForm(this.oApplication, SAPbouiCOM.BoFormBorderStyle.fbs_Fixed, "CFL1", "CFL1", 150, 350, true, 0, "Exemplo de Choose From List");

            UserDataSourceHelper.AddUserDataSource(this.oForm, "EditDS", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 254);
            UserDataSourceHelper.AddUserDataSource(this.oForm, "EditDSN", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 254);

            AddChooseFromList();
            this.oEditTxt   = UIHelper.AddEditTextAoFormulario(this.oForm, "EditTxt", 120, 0, 90, 0, "StaticTxt", false, 0, 0);
            this.oEditTxtN  = UIHelper.AddEditTextAoFormulario(this.oForm, "EditTxtN", 120, 0, 105, 0, "EditTxt", false, 0, 0);
            this.oStaticTxt = UIHelper.AddStaticTextAoFormulario(this.oForm, "StaticTxt", 10, 0, 90, 0, "Cliente");


            this.oStaticExplain  = UIHelper.AddStaticTextAoFormulario(this.oForm, "Explain", 10, 200, 10, 0, "São dois choosen From List Aqui no Formulário");
            this.oStaticExplain1 = UIHelper.AddStaticTextAoFormulario(this.oForm, "Explain1", 10, 300, 25, 0, "Um deles é ativado pressionando TAB no Edit Text...");
            this.oStaticExplain2 = UIHelper.AddStaticTextAoFormulario(this.oForm, "Explain2", 10, 300, 40, 0, "Somente é mostrado quando o Parceiro de Negócios é Cleinte...");
            this.oStaticExplain3 = UIHelper.AddStaticTextAoFormulario(this.oForm, "Explain3", 10, 300, 55, 0, "O Outro Choose From List é ativado pelo Botão...");
            this.oStaticExplain4 = UIHelper.AddStaticTextAoFormulario(this.oForm, "Explain4", 10, 300, 70, 0, "Mostra todos os parceiros de negocios ....");

            string sImagem = System.Windows.Forms.Application.StartupPath + @"\CFL.BMP";;

            this.oButton = UIHelper.AddBotaoImagemAoFormulario(this.oForm, "Button", 199, 20, 88, 20, sImagem);

            this.oEditTxt.DataBind.SetBound(true, "", "EditDS");
            this.oEditTxtN.DataBind.SetBound(true, "", "EditDSN");

            this.oEditTxt.ChooseFromListUID = "CFL1";
            this.oButton.ChooseFromListUID  = "CFL2";

            this.oApplication.ItemEvent += OApplication_ItemEvent;

            this.oForm.Visible = true;
        }
Example #3
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.lObjCmbPrefixes = ((SAPbouiCOM.ComboBox)(this.GetItem("cbPrefix").Specific));
     this.lObjBtnAccept   = ((SAPbouiCOM.Button)(this.GetItem("BtnOk").Specific));
     this.StaticText0     = ((SAPbouiCOM.StaticText)(this.GetItem("Item_3").Specific));
     this.lObjETActiveP   = ((SAPbouiCOM.EditText)(this.GetItem("txtActive").Specific));
     this.OnCustomInitialize();
 }
Example #4
0
        /// <summary>
        /// Initialize components. Called by framework after form created.
        /// </summary>
        ///

        public override void OnInitializeComponent()
        {
            this.Grid0 = ((SAPbouiCOM.Grid)(this.GetItem("Item_0").Specific));
            this.Grid0.DoubleClickAfter += new SAPbouiCOM._IGridEvents_DoubleClickAfterEventHandler(this.Grid0_DoubleClickAfter);
            this.Grid0.PressedAfter     += new SAPbouiCOM._IGridEvents_PressedAfterEventHandler(this.OnClickListener);
            this.Edit1 = ((SAPbouiCOM.EditText)(this.GetItem("Item_1").Specific));
            this.Edit1.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit1_DoubleClickBefore);
            this.StaticText0              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_2").Specific));
            this.Edit2 = ((SAPbouiCOM.EditText)(this.GetItem("Item_3").Specific));
            this.Edit2.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit2_DoubleClickBefore);
            this.StaticText1              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_4").Specific));
            this.StaticText2              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_5").Specific));
            this.Edit3 = ((SAPbouiCOM.EditText)(this.GetItem("Item_6").Specific));
            this.Edit3.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit3_DoubleClickBefore);
            this.StaticText3              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_7").Specific));
            this.Edit4 = ((SAPbouiCOM.EditText)(this.GetItem("Item_8").Specific));
            this.Edit4.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit4_DoubleClickBefore);
            this.StaticText4              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_9").Specific));
            this.Edit5 = ((SAPbouiCOM.EditText)(this.GetItem("Item_10").Specific));
            this.Edit5.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit5_DoubleClickBefore);
            this.StaticText5              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_11").Specific));
            this.Edit6 = ((SAPbouiCOM.EditText)(this.GetItem("Item_12").Specific));
            this.Edit6.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit6_DoubleClickBefore);
            this.StaticText6              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_13").Specific));
            this.Edit7 = ((SAPbouiCOM.EditText)(this.GetItem("Item_14").Specific));
            this.Edit7.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit7_DoubleClickBefore);
            this.StaticText7              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_15").Specific));
            this.Edit8 = ((SAPbouiCOM.EditText)(this.GetItem("Item_16").Specific));
            this.Edit8.DoubleClickBefore     += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.Edit8_DoubleClickBefore);
            this.FillTableButton              = ((SAPbouiCOM.Button)(this.GetItem("Item_17").Specific));
            this.FillTableButton.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.FillTableButton_ClickBefore);
            this.RefreshButton              = ((SAPbouiCOM.Button)(this.GetItem("Item_18").Specific));
            this.RefreshButton.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.ResetButton);
            this.ComboBox0 = ((SAPbouiCOM.ComboBox)(this.GetItem("Item_19").Specific));
            this.ComboBox0.ComboSelectAfter += new SAPbouiCOM._IComboBoxEvents_ComboSelectAfterEventHandler(this.ComboBox0_ComboSelectAfter);
            this.StaticText8              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_20").Specific));
            this.StaticText9              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_21").Specific));
            this.Grid1                    = ((SAPbouiCOM.Grid)(this.GetItem("Item_22").Specific));
            this.StaticText10             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_23").Specific));
            this.Edit0                    = ((SAPbouiCOM.EditText)(this.GetItem("Item_24").Specific));
            this.Edit0.DoubleClickBefore += new SAPbouiCOM._IEditTextEvents_DoubleClickBeforeEventHandler(this.EditText8_DoubleClickBefore);
            this.LinkedButton0            = ((SAPbouiCOM.LinkedButton)(this.GetItem("Item_25").Specific));
            this.StaticText11             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_26").Specific));
            this.Button2                  = ((SAPbouiCOM.Button)(this.GetItem("Item_27").Specific));
            this.Button2.ClickBefore     += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.Button2_ClickBefore);

            //
            this.listOfEditText = this.CM_Obj.addItemsToList(this.Edit0, this.Edit1, this.Edit2, this.Edit3, this.Edit4, this.Edit5, this.Edit6, this.Edit7, this.Edit8);
            //
            this.CountButton                = ((SAPbouiCOM.Button)(this.GetItem("Item_31").Specific));
            this.CountButton.ClickBefore   += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.CountTotal);
            this.GetItem("Item_31").Visible = false;
            this.GetItem("Item_19").Enabled = false;
            this.Grid2 = ((SAPbouiCOM.Grid)(this.GetItem("Item_32").Specific));
            this.AuthenticationButton              = ((SAPbouiCOM.Button)(this.GetItem("Item_29").Specific));
            this.AuthenticationButton.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.Button0_ClickBefore);
            this.OnCustomInitialize();
        }
        public static string Current_User_Name()
        {
            string sNombreUsu = "";

            SAPbouiCOM.Form       oForm   = Application.SBO_Application.Forms.GetForm("169", 0); //Toma la Descripcion del Usuario Actual del Menu Principal
            SAPbouiCOM.StaticText oStatic = (SAPbouiCOM.StaticText)oForm.Items.Item("8").Specific;
            sNombreUsu = oStatic.Caption;
            return((string)sNombreUsu);
        }
Example #6
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.StaticText0           = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.StaticText1           = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.EditText0             = ((SAPbouiCOM.EditText)(this.GetItem("txt_frd").Specific));
     this.EditText1             = ((SAPbouiCOM.EditText)(this.GetItem("txt_tod").Specific));
     this.Button0               = ((SAPbouiCOM.Button)(this.GetItem("Item_4").Specific));
     this.Button0.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button0_PressedAfter);
     this.OnCustomInitialize();
 }
Example #7
0
 private void setLabelCaption(SAPbouiCOM.Form form, string id, string cap)
 {
     try
     {
         SAPbouiCOM.StaticText oStatic = form.Items.Item(id).Specific;
         oStatic.Caption = cap;
     }
     catch (Exception)
     {
     }
 }
Example #8
0
 public void changeLabel(SAPbouiCOM.StaticText StaticText0, SAPbouiCOM.StaticText StaticText1, SAPbouiCOM.StaticText StaticText2, SAPbouiCOM.StaticText StaticText3, SAPbouiCOM.StaticText StaticText4, SAPbouiCOM.StaticText StaticText5, SAPbouiCOM.StaticText StaticText6, SAPbouiCOM.StaticText StaticText7, String par1, String par2, String par3, String par4, String par5, String par6, String par7, String par8)
 {
     StaticText0.Caption = par1;
     StaticText1.Caption = par2;
     StaticText2.Caption = par3;
     StaticText3.Caption = par4;
     StaticText4.Caption = par5;
     StaticText5.Caption = par6;
     StaticText6.Caption = par7;
     StaticText7.Caption = par8;
 }
        public void CreateModalForm()
        {
            this.oForm = UIHelper.CriarForm(this.oApplication, SAPbouiCOM.BoFormBorderStyle.fbs_Fixed, "Modal1", "Modal1", 170, 150, true, 0, "Formulário Modal");



            this.oButtonOK            = UIHelper.AddBotaoAoFormulario(this.oForm, "1", 10, 0, 100, 0, "Ok", false);
            this.oStaticTextMeuStatic = UIHelper.AddStaticTextAoFormulario(this.oForm, "st01", 0, 160, 0, 0, "Eu sou um Fomrulário Modal!!");

            this.oForm.Visible = true;
            this.bModal        = true;
        }
Example #10
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.mObjTxtDate   = ((SAPbouiCOM.EditText)(this.GetItem("txtDate").Specific));
     this.mObjLblDate   = ((SAPbouiCOM.StaticText)(this.GetItem("lblDate").Specific));
     this.mObjLblAuct   = ((SAPbouiCOM.StaticText)(this.GetItem("lblAuct").Specific));
     this.mObjBtnSearch = ((SAPbouiCOM.Button)(this.GetItem("btnSearch").Specific));
     this.mObjSMatrix   = ((SAPbouiCOM.Matrix)(this.GetItem("mtxSeller").Specific));
     this.mObjBtnSave   = ((SAPbouiCOM.Button)(this.GetItem("btnSave").Specific));
     this.mObjBtnPayR   = ((SAPbouiCOM.Button)(this.GetItem("btnPaymR").Specific));
     this.mObjCbAuct    = ((SAPbouiCOM.ComboBox)(this.GetItem("cbAuctN").Specific));
     this.OnCustomInitialize();
 }
Example #11
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.btnOk       = ((SAPbouiCOM.Button)(this.GetItem("btnOkIns").Specific));
     this.btnFind     = ((SAPbouiCOM.Button)(this.GetItem("BtnFind").Specific));
     this.lObjTxtDate = ((SAPbouiCOM.EditText)(this.GetItem("txtDateIns").Specific));
     this.lblDate     = ((SAPbouiCOM.StaticText)(this.GetItem("Item_2").Specific));
     this.lObjMatrix  = ((SAPbouiCOM.Matrix)(this.GetItem("mtxInsp").Specific));
     this.ConfigForm();
     this.Button1        = ((SAPbouiCOM.Button)(this.GetItem("btnAddD").Specific));
     this.lObjBtnCer     = ((SAPbouiCOM.Button)(this.GetItem("btnCert").Specific));
     this.lObjBtnDelInsp = ((SAPbouiCOM.Button)(this.GetItem("btnDel").Specific));
     this.OnCustomInitialize();
 }
 public static void stxtDire(SAPbouiCOM.Form oForm)
 {
     oItem               = oForm.Items.Add("stxtDire", SAPbouiCOM.BoFormItemTypes.it_STATIC);
     oItem.Top           = 300;
     oItem.Height        = 20;
     oItem.Width         = 200;
     oItem.Left          = 290;
     oItem.FontSize      = 14;
     oStaticText         = ((SAPbouiCOM.StaticText)(oItem.Specific));
     oStaticText.Caption = "";
     oItem.FromPane      = 7;
     oItem.ToPane        = 7;
 }
Example #13
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.lObjTxtClient    = ((SAPbouiCOM.EditText)(this.GetItem("txtClient").Specific));
     this.StaticText0      = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.lObjMtxRejectOut = ((SAPbouiCOM.Matrix)(this.GetItem("mtxReject").Specific));
     this.lObjBtnSearch    = ((SAPbouiCOM.Button)(this.GetItem("btnSearch").Specific));
     this.lObjBtnExit      = ((SAPbouiCOM.Button)(this.GetItem("btnOutput").Specific));
     this.lObjBtnInvoice   = ((SAPbouiCOM.Button)(this.GetItem("btnInvo").Specific));
     // this.lObjChckBox = ((SAPbouiCOM.CheckBox)(this.GetItem("ChckP").Specific));
     this.lObjChckBox      = ((SAPbouiCOM.CheckBox)(this.UIAPIRawForm.Items.Item("ChckP").Specific));
     this.lObjEdTxtDocDate = ((SAPbouiCOM.EditText)(this.GetItem("txtSpD").Specific));
     this.lObjLbl          = ((SAPbouiCOM.StaticText)(this.GetItem("lblSpd").Specific));
     this.OnCustomInitialize();
 }
Example #14
0
    private string getLabelCaption(SAPbouiCOM.Form form, string id)
    {
        string ret = "";

        try
        {
            SAPbouiCOM.StaticText oStatic = form.Items.Item(id).Specific;
            ret = oStatic.Caption;
        }
        catch (Exception)
        {
        }
        return(ret);
    }
Example #15
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.btnSave              = ((SAPbouiCOM.Button)(this.GetItem("1").Specific));
     this.btnSave.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.btnSave_ClickBefore);
     this.btnCancel            = ((SAPbouiCOM.Button)(this.GetItem("2").Specific));
     this.lblCode              = ((SAPbouiCOM.StaticText)(this.GetItem("lblCode").Specific));
     this.lblName              = ((SAPbouiCOM.StaticText)(this.GetItem("lblName").Specific));
     this.txtCode              = ((SAPbouiCOM.EditText)(this.GetItem("txtCode").Specific));
     this.txtName              = ((SAPbouiCOM.EditText)(this.GetItem("txtName").Specific));
     this.lblType              = ((SAPbouiCOM.StaticText)(this.GetItem("lblType").Specific));
     this.cbTypes              = ((SAPbouiCOM.ComboBox)(this.GetItem("cbTypes").Specific));
     this.lblDoc      = ((SAPbouiCOM.StaticText)(this.GetItem("lblDoc").Specific));
     this.txtDocEntry = ((SAPbouiCOM.EditText)(this.GetItem("txtDoc").Specific));
     this.OnCustomInitialize();
 }
        /// <summary>
        /// Initialize components. Called by framework after form created.
        /// </summary>
        public override void OnInitializeComponent()
        {
            this.Button0             = ((SAPbouiCOM.Button)(this.GetItem("Item_0").Specific));
            this.Button0.ClickAfter += new SAPbouiCOM._IButtonEvents_ClickAfterEventHandler(this.CopyToGoodsIssue);
            this.GIMatrix            = ((SAPbouiCOM.Matrix)(this.GetItem("13").Specific));
            this.StaticText0         = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
            this.EditTextToBranch    = ((SAPbouiCOM.EditText)(this.GetItem("Item_2").Specific));
            this.EditTextToWhs       = ((SAPbouiCOM.EditText)(this.GetItem("Item_3").Specific));
            this.EditTextToWhs.ChooseFromListAfter += new SAPbouiCOM._IEditTextEvents_ChooseFromListAfterEventHandler(this.EditTextWhsUDF_ChooseFromListAfter);
            this.StaticText1 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_5").Specific));
            this.OIGE        = this.UIAPIRawForm.DataSources.DBDataSources.Item("OIGE");


            this.OnCustomInitialize();
        }
Example #17
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.mTxtMoveType  = ((SAPbouiCOM.StaticText)(this.GetItem("txtMvType").Specific));
     this.mTxtDateStart = ((SAPbouiCOM.StaticText)(this.GetItem("txtDtStr").Specific));
     this.mTxtDateFinal = ((SAPbouiCOM.StaticText)(this.GetItem("txtDtFnl").Specific));
     this.mCmbMvType    = ((SAPbouiCOM.ComboBox)(this.GetItem("cbMvType").Specific));
     this.mEdtDateStart = ((SAPbouiCOM.EditText)(this.GetItem("edtDtStr").Specific));
     this.mTxtCheckNum  = ((SAPbouiCOM.StaticText)(this.GetItem("txtChkNum").Specific));
     this.mEdtCheckNum  = ((SAPbouiCOM.EditText)(this.GetItem("edtChkNum").Specific));
     this.mEdtDateFinal = ((SAPbouiCOM.EditText)(this.GetItem("edtDtFnl").Specific));
     this.mBtnSearch    = ((SAPbouiCOM.Button)(this.GetItem("btnSearch").Specific));
     this.mMtxChecks    = ((SAPbouiCOM.Matrix)(this.GetItem("mtxChecks").Specific));
     this.mBtnSave      = ((SAPbouiCOM.Button)(this.GetItem("btnSave").Specific));
     this.OnCustomInitialize();
 }
Example #18
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.StaticText0             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.EditText0               = ((SAPbouiCOM.EditText)(this.GetItem("Item_1").Specific));
     this.EditText0.KeyDownAfter += new SAPbouiCOM._IEditTextEvents_KeyDownAfterEventHandler(this.EditText0_KeyDownAfter);
     this.StaticText1             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_2").Specific));
     this.EditText1               = ((SAPbouiCOM.EditText)(this.GetItem("Item_3").Specific));
     this.EditText1.KeyDownAfter += new SAPbouiCOM._IEditTextEvents_KeyDownAfterEventHandler(this.EditText1_KeyDownAfter);
     this.Button0               = ((SAPbouiCOM.Button)(this.GetItem("Item_5").Specific));
     this.Button0.ClickBefore  += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.Button0_ClickBefore);
     this.Button1               = ((SAPbouiCOM.Button)(this.GetItem("Item_6").Specific));
     this.Matrix1               = ((SAPbouiCOM.Matrix)(this.GetItem("Item_7").Specific));
     this.Matrix1.KeyDownAfter += new SAPbouiCOM._IMatrixEvents_KeyDownAfterEventHandler(this.Matrix1_KeyDownAfter);
     this.OnCustomInitialize();
 }
        /// <summary>
        /// Initialize components. Called by framework after form created.
        /// </summary>
        public override void OnInitializeComponent()
        {
            this.btnSave = ((SAPbouiCOM.Button)(this.GetItem("1").Specific));
            this.btnSave.ClickBefore += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.btnSave_ClickBefore);
            this.btnCancel = ((SAPbouiCOM.Button)(this.GetItem("2").Specific));
            this.lblCode = ((SAPbouiCOM.StaticText)(this.GetItem("lblCode").Specific));
            this.lblName = ((SAPbouiCOM.StaticText)(this.GetItem("lblName").Specific));
            this.txtCode = ((SAPbouiCOM.EditText)(this.GetItem("txtCode").Specific));
            this.txtName = ((SAPbouiCOM.EditText)(this.GetItem("txtName").Specific));
            this.lblType = ((SAPbouiCOM.StaticText)(this.GetItem("lblType").Specific));
            this.cbTypes = ((SAPbouiCOM.ComboBox)(this.GetItem("cbTypes").Specific));
            this.lblDoc = ((SAPbouiCOM.StaticText)(this.GetItem("lblDoc").Specific));
            this.txtDocEntry = ((SAPbouiCOM.EditText)(this.GetItem("txtDoc").Specific));
            this.OnCustomInitialize();

        }
Example #20
0
 public override void OnInitializeComponent()
 {
     //this.lObjCompany = ((SAPbobsCOM.Company)Application.SBO_Application.Company.GetDICompany());
     //   this.lObjCompany = ((SAPbobsCOM.Company)(typeof(SAPbouiCOM.Framework.Application).Application.Company.GetDICompany()));
     this.lObjButtonOk   = ((SAPbouiCOM.Button)(this.GetItem("btnOkChk").Specific));
     this.lObjEdTxtDate  = ((SAPbouiCOM.EditText)(this.GetItem("txtDateIns").Specific));
     this.lObjStTxtOK    = ((SAPbouiCOM.StaticText)(this.GetItem("lbl").Specific));
     this.lObjMatrix     = ((SAPbouiCOM.Matrix)(this.GetItem("MtxChkIns").Specific));
     this.lObjButtonFind = ((SAPbouiCOM.Button)(this.GetItem("btnFindIns").Specific));
     this.StaticText0    = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.lObjMatrix.AutoResizeColumns();
     //   MemoryUtility.ReleaseComObject();
     this.EditText0 = ((SAPbouiCOM.EditText)(this.GetItem("Item_0").Specific));
     FormConfig();
     this.OnCustomInitialize();
 }
Example #21
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.mTxtFolio    = ((SAPbouiCOM.StaticText)(this.GetItem("txtFolio").Specific));
     this.mEdtFolio    = ((SAPbouiCOM.EditText)(this.GetItem("edtFolio").Specific));
     this.mTxtBank     = ((SAPbouiCOM.StaticText)(this.GetItem("txtBank").Specific));
     this.mTxtAccnt    = ((SAPbouiCOM.StaticText)(this.GetItem("txtAccnt").Specific));
     this.mMtxSellers  = ((SAPbouiCOM.Matrix)(this.GetItem("mtxSellers").Specific));
     this.mCmbBank     = ((SAPbouiCOM.ComboBox)(this.GetItem("cmbBank").Specific));
     this.mCmbAcct     = ((SAPbouiCOM.ComboBox)(this.GetItem("cmbAcct").Specific));
     this.mBtnGenerate = ((SAPbouiCOM.Button)(this.GetItem("btnGen").Specific));
     this.Button0      = ((SAPbouiCOM.Button)(this.GetItem("Item_0").Specific));
     this.lObjBtnCC    = ((SAPbouiCOM.Button)(this.GetItem("btnOpCC").Specific));
     this.CboAuctions  = ((SAPbouiCOM.ComboBox)(this.GetItem("cboAuct").Specific));
     this.CboAuctions.ComboSelectAfter += new SAPbouiCOM._IComboBoxEvents_ComboSelectAfterEventHandler(this.cboAuctions_ComboSelectAfter);
     this.OnCustomInitialize();
 }
        public RightClick()
        {
            AppHelper.SetApplication(ref this.oApplication);
            AddMenu();
            this.oForm    = UIHelper.CriarForm(this.oApplication, SAPbouiCOM.BoFormBorderStyle.fbs_Sizable, "RClick", "RClick", 0, 0, true, 0, "Exemplo de Click no botão direito", 150, 400, 0, 0);
            this.oEditTxt = UIHelper.AddEditTextAoFormulario(this.oForm, "EditTxt", 170, 0, 90, 0, "", false, 0, 0);
            this.oExpTxt1 = UIHelper.AddStaticTextAoFormulario(this.oForm, "ExpTxt1", 10, 350, 90, 0, "Click Direito No Text Box", "EditTxt");
            this.oExpTxt2 = UIHelper.AddStaticTextAoFormulario(this.oForm, "ExpTxt2", 10, 350, 35, 0, "Click Direito no Text Box , 2 menus adcionar irão aparecer..", "EditTxt");
            this.oExpTxt3 = UIHelper.AddStaticTextAoFormulario(this.oForm, "ExpTxt3", 10, 350, 50, 0, "No menu de dados e no botão direto sempre aparecem no Menu de dados..", "EditTxt");
            this.oExpTxt4 = UIHelper.AddStaticTextAoFormulario(this.oForm, "ExpTxt4", 10, 350, 65, 0, "Somente com o botão direito sobre a caixa de teste é que o menu aparece sobre a caixa de Texto..", "EditTxt");

            oApplication.MenuEvent += OApplication_MenuEvent;
            //oApplication.ItemEvent += OApplication_ItemEvent;
            oApplication.RightClickEvent += OApplication_RightClickEvent;

            this.oForm.Visible = true;
        }
Example #23
0
 public override void OnInitializeComponent()
 {
     this.StaticText0             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.StaticText1             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.EditText0               = ((SAPbouiCOM.EditText)(this.GetItem("txt_frd").Specific));
     this.EditText1               = ((SAPbouiCOM.EditText)(this.GetItem("txt_tod").Specific));
     this.StaticText2             = ((SAPbouiCOM.StaticText)(this.GetItem("Item_4").Specific));
     this.EditText2               = ((SAPbouiCOM.EditText)(this.GetItem("txt_lvl").Specific));
     this.Grid0                   = ((SAPbouiCOM.Grid)(this.GetItem("Item_6").Specific));
     this.Grid0.DoubleClickAfter += new SAPbouiCOM._IGridEvents_DoubleClickAfterEventHandler(this.Grid0_DoubleClickAfter);
     this.Button0                 = ((SAPbouiCOM.Button)(this.GetItem("bt_load").Specific));
     this.Button0.PressedAfter   += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button0_PressedAfter);
     this.Button1                 = ((SAPbouiCOM.Button)(this.GetItem("bt_r1").Specific));
     this.Button1.PressedAfter   += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button1_PressedAfter);
     this.Button2                 = ((SAPbouiCOM.Button)(this.GetItem("bt_r2").Specific));
     this.Button2.PressedAfter   += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button2_PressedAfter);
     this.OnCustomInitialize();
 }
    private void setMatrixItem(SAPbouiCOM.Matrix oMatrix, string Col, int Row, string val)
    {
        string sValue = "";

        try
        {
            if (oMatrix.Columns.Item(Col) == null)
            {
                trace("setMatrixItem Cannot found col: " + Col);
                return;
            }
            if (oMatrix.Columns.Item(Col).Cells.Item(Row) == null)
            {
                trace("setMatrixItem Cannot found col: " + Col + ", row: " + Row);
                return;
            }
            SAPbouiCOM.Cell cell = oMatrix.Columns.Item(Col).Cells.Item(Row);
            if (cell.Specific is SAPbouiCOM.EditText)
            {
                SAPbouiCOM.EditText oEt = (SAPbouiCOM.EditText)oMatrix.Columns.Item(Col).Cells.Item(Row).Specific;
                oEt.Value = val;
                return;
            }
            if (cell.Specific is SAPbouiCOM.StaticText)
            {
                SAPbouiCOM.StaticText oStatic = (SAPbouiCOM.StaticText)oMatrix.Columns.Item(Col).Cells.Item(Row).Specific;
                oStatic.Caption = val;
                return;
            }
            if (cell.Specific is SAPbouiCOM.ComboBox)
            {
                SAPbouiCOM.ComboBox oCB = (SAPbouiCOM.ComboBox)oMatrix.Columns.Item(Col).Cells.Item(Row).Specific;
                oCB.Select(val);
                return;
            }
        }
        catch (Exception ex)
        {
            errorLog("Can't find row:" + Row.ToString() + ",col:" + Col + "\r\n" + ex.Message);
        }
    }
Example #25
0
 public override void OnInitializeComponent()
 {
     this.StaticText0 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.StaticText1 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_3").Specific));
     this.StaticText2 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_5").Specific));
     this.StaticText3 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_6").Specific));
     this.StaticText4 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_10").Specific));
     this.StaticText5 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_13").Specific));
     this.StaticText6 = ((SAPbouiCOM.StaticText)(this.GetItem("Item_14").Specific));
     this.ComboBox0   = ((SAPbouiCOM.ComboBox)(this.GetItem("Item_2").Specific));
     this.ComboBox0.ComboSelectAfter += new SAPbouiCOM._IComboBoxEvents_ComboSelectAfterEventHandler(this.ComboBox0_ComboSelectAfter);
     this.ComboBox1 = ((SAPbouiCOM.ComboBox)(this.GetItem("cbo_btype").Specific));
     this.ComboBox1.ComboSelectAfter += new SAPbouiCOM._IComboBoxEvents_ComboSelectAfterEventHandler(this.ComboBox1_ComboSelectAfter);
     this.CheckBox0 = ((SAPbouiCOM.CheckBox)(this.GetItem("chk_new").Specific));
     this.CheckBox0.PressedAfter += new SAPbouiCOM._ICheckBoxEvents_PressedAfterEventHandler(this.CheckBox0_PressedAfter);
     this.EditText0 = ((SAPbouiCOM.EditText)(this.GetItem("txt_bpcode").Specific));
     this.EditText0.LostFocusAfter += new SAPbouiCOM._IEditTextEvents_LostFocusAfterEventHandler(this.EditText0_LostFocusAfter);
     this.EditText1             = ((SAPbouiCOM.EditText)(this.GetItem("txt_prjn").Specific));
     this.EditText2             = ((SAPbouiCOM.EditText)(this.GetItem("txt_period").Specific));
     this.EditText3             = ((SAPbouiCOM.EditText)(this.GetItem("txt_fr").Specific));
     this.EditText4             = ((SAPbouiCOM.EditText)(this.GetItem("txt_to").Specific));
     this.Grid0                 = ((SAPbouiCOM.Grid)(this.GetItem("grd_lst").Specific));
     this.Button0               = ((SAPbouiCOM.Button)(this.GetItem("bt_n").Specific));
     this.Button0.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button0_PressedAfter);
     this.Button1               = ((SAPbouiCOM.Button)(this.GetItem("bt_v").Specific));
     this.Button1.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button1_PressedAfter);
     this.Button2               = ((SAPbouiCOM.Button)(this.GetItem("bt_e").Specific));
     this.Button2.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button2_PressedAfter);
     this.Button3               = ((SAPbouiCOM.Button)(this.GetItem("bt_d").Specific));
     this.Button3.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button3_PressedAfter);
     this.Button4               = ((SAPbouiCOM.Button)(this.GetItem("bt_l").Specific));
     this.Button4.PressedAfter += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button4_PressedAfter);
     this.StaticText7           = ((SAPbouiCOM.StaticText)(this.GetItem("Item_1").Specific));
     this.EditText5             = ((SAPbouiCOM.EditText)(this.GetItem("txt_tu").Specific));
     this.StaticText8           = ((SAPbouiCOM.StaticText)(this.GetItem("Item_4").Specific));
     this.EditText6             = ((SAPbouiCOM.EditText)(this.GetItem("txt_ktu").Specific));
     this.StaticText9           = ((SAPbouiCOM.StaticText)(this.GetItem("Item_8").Specific));
     this.EditText7             = ((SAPbouiCOM.EditText)(this.GetItem("txt_note").Specific));
     this.OnCustomInitialize();
 }
Example #26
0
        private void LoadForm()
        {
            SAPbouiCOM.Item lItmLblBanco = null;
            mEdtAccountField = mObjForm.Items.Item(STR_SEARCH_UID).Specific as SAPbouiCOM.EditText;

            lItmLblBanco = mObjForm.Items.Add("txtFormat", SAPbouiCOM.BoFormItemTypes.it_STATIC);
            SAPbouiCOM.Item lItmBtnImport = mObjForm.Items.Add(STR_IMPORT_BUTTON_UID, SAPbouiCOM.BoFormItemTypes.it_BUTTON);
            mBtnImport         = lItmBtnImport.Specific as SAPbouiCOM.Button;
            mTxtSelectedFormat = lItmLblBanco.Specific as SAPbouiCOM.StaticText;

            lItmLblBanco.Top     = mObjForm.Items.Item("6").Top;
            lItmLblBanco.Left    = mObjForm.Items.Item("6").Left + 40;
            lItmLblBanco.Width   = 200;
            lItmLblBanco.Visible = false;

            lItmBtnImport.Top     = lItmLblBanco.Top + 15;
            lItmBtnImport.Left    = lItmLblBanco.Left;
            lItmBtnImport.Visible = false;
            mBtnImport.Caption    = "Importar";

            LoadEvents();
        }
        public Picker()
        {
            AppHelper.SetApplication(ref this.oApplication);

            this.oForm = UIHelper.CriarForm(this.oApplication, SAPbouiCOM.BoFormBorderStyle.fbs_Fixed, "PickerForm", "PickerForm", 150, 350, true, 0, "Exemplo de Selecionador", 0, 0, 100, 400);

            UserDataSourceHelper.AddUserDataSource(this.oForm, "DateDS", SAPbouiCOM.BoDataType.dt_DATE, 254);
            UserDataSourceHelper.AddUserDataSource(this.oForm, "CalcDS", SAPbouiCOM.BoDataType.dt_PRICE, 254);
            UserDataSourceHelper.AddUserDataSource(this.oForm, "CLFDS", SAPbouiCOM.BoDataType.dt_SHORT_TEXT, 254);

            AddChooseFromList();

            this.oForm.Visible = true;


            this.oForm.Freeze(true);

            this.oStaticHead = UIHelper.AddStaticTextAoFormulario(this.oForm, "StaticHead", 7, 350, 8, 44, "São 3 exemplos de selecionar Informações", "EditDate");

            this.oEditDate = UIHelper.AddEditTextAoFormulario(this.oForm, "EditDate", 157, 80, 65, 14, "", false, 0, 0);
            this.oEditDate.DataBind.SetBound(true, "", "DateDS");
            this.oStaticDate = UIHelper.AddStaticTextAoFormulario(this.oForm, "StaticDate", 7, 148, 65, 14, "Data:", "EditDate");

            this.oEditPrice = UIHelper.AddEditTextAoFormulario(this.oForm, "EditPrice", 157, 80, 46, 14, "", false, 0, 0);
            this.oEditPrice.DataBind.SetBound(true, "", "CalcDS");
            this.oStaticPrice = UIHelper.AddStaticTextAoFormulario(this.oForm, "StatPrice", 7, 148, 46, 14, "Preço:", "EditPrice");



            this.oEditCLF = UIHelper.AddEditTextAoFormulario(this.oForm, "EditCLF", 157, 80, 85, 14, "", false, 0, 0);
            this.oEditCLF.DataBind.SetBound(true, "", "CLFDS");
            this.oEditCLF.ChooseFromListUID = "CFL1";
            this.oStaticCLF = UIHelper.AddStaticTextAoFormulario(this.oForm, "oStaticCLF", 7, 148, 85, 14, "CLF:", "EditCLF");

            this.oApplication.ItemEvent += OApplication_ItemEvent;

            this.oForm.Freeze(false);
        }
Example #28
0
 public override void OnInitializeComponent()
 {
     this.StaticText0              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.Grid0                    = ((SAPbouiCOM.Grid)(this.GetItem("grd_lst").Specific));
     this.Grid0.PressedAfter      += new SAPbouiCOM._IGridEvents_PressedAfterEventHandler(this.Grid0_PressedAfter);
     this.OptionBtn0               = ((SAPbouiCOM.OptionBtn)(this.GetItem("op_cur").Specific));
     this.OptionBtn0.PressedAfter += new SAPbouiCOM._IOptionBtnEvents_PressedAfterEventHandler(this.OptionBtn0_PressedAfter);
     this.OptionBtn1               = ((SAPbouiCOM.OptionBtn)(this.GetItem("op_appr").Specific));
     this.OptionBtn1.PressedAfter += new SAPbouiCOM._IOptionBtnEvents_PressedAfterEventHandler(this.OptionBtn1_PressedAfter);
     this.OptionBtn2               = ((SAPbouiCOM.OptionBtn)(this.GetItem("op_rej").Specific));
     this.OptionBtn2.PressedAfter += new SAPbouiCOM._IOptionBtnEvents_PressedAfterEventHandler(this.OptionBtn2_PressedAfter);
     this.OptionBtn3               = ((SAPbouiCOM.OptionBtn)(this.GetItem("op_all").Specific));
     this.OptionBtn3.PressedAfter += new SAPbouiCOM._IOptionBtnEvents_PressedAfterEventHandler(this.OptionBtn3_PressedAfter);
     this.Grid1                    = ((SAPbouiCOM.Grid)(this.GetItem("grd_pro").Specific));
     this.Grid2                    = ((SAPbouiCOM.Grid)(this.GetItem("grd_info").Specific));
     this.StaticText1              = ((SAPbouiCOM.StaticText)(this.GetItem("Item_8").Specific));
     this.EditText0                = ((SAPbouiCOM.EditText)(this.GetItem("txt_comm").Specific));
     this.Button0                  = ((SAPbouiCOM.Button)(this.GetItem("bt_appr").Specific));
     this.Button0.PressedAfter    += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button0_PressedAfter);
     this.Button1                  = ((SAPbouiCOM.Button)(this.GetItem("bt_rej").Specific));
     this.Button1.PressedAfter    += new SAPbouiCOM._IButtonEvents_PressedAfterEventHandler(this.Button1_PressedAfter);
     this.ResizeAfter             += new SAPbouiCOM.Framework.FormBase.ResizeAfterHandler(this.Form_ResizeAfter);
     this.OnCustomInitialize();
 }
 private void setLabelCaption(SAPbouiCOM.Form form, string id, string cap)
 {
     SAPbouiCOM.StaticText oItem = null;
     try
     {
         oItem         = (SAPbouiCOM.StaticText)form.Items.Item(id).Specific;
         oItem.Caption = cap;
     }
     catch (Exception)
     {
     }
     finally
     {
         /*
          * try
          * {
          *  if (oItem != null)
          *      System.Runtime.InteropServices.Marshal.ReleaseComObject(oItem);
          *  oItem = null;
          * }
          * catch (Exception) { }
          */
     }
 }
Example #30
0
 /// <summary>
 /// Initialize components. Called by framework after form created.
 /// </summary>
 public override void OnInitializeComponent()
 {
     this.StaticText3                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_8").Specific));
     this.StaticText4                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_10").Specific));
     this.StaticText5                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_11").Specific));
     this.StaticText6                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_12").Specific));
     this.EditText3                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_13").Specific));
     this.StaticText0                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_0").Specific));
     this.EditText0                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_1").Specific));
     this.StaticText1                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_2").Specific));
     this.EditText1                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_3").Specific));
     this.StaticText2                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_4").Specific));
     this.EditText2                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_5").Specific));
     this.LinkedButton0                 = ((SAPbouiCOM.LinkedButton)(this.GetItem("Item_6").Specific));
     this.StaticText7                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_7").Specific));
     this.EditText4                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_9").Specific));
     this.EditText5                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_14").Specific));
     this.StaticText8                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_15").Specific));
     this.StaticText9                   = ((SAPbouiCOM.StaticText)(this.GetItem("Item_18").Specific));
     this.EditText6                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_19").Specific));
     this.LinkedButton1                 = ((SAPbouiCOM.LinkedButton)(this.GetItem("Item_20").Specific));
     this.StaticText10                  = ((SAPbouiCOM.StaticText)(this.GetItem("Item_21").Specific));
     this.EditText7                     = ((SAPbouiCOM.EditText)(this.GetItem("Item_22").Specific));
     this.PictureBox0                   = ((SAPbouiCOM.PictureBox)(this.GetItem("Item_23").Specific));
     this.Button0                       = ((SAPbouiCOM.Button)(this.GetItem("Item_24").Specific));
     this.Button0.ClickBefore          += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.Button0_ClickBefore);
     this.Button1                       = ((SAPbouiCOM.Button)(this.GetItem("Item_25").Specific));
     this.Button1.ClickBefore          += new SAPbouiCOM._IButtonEvents_ClickBeforeEventHandler(this.Button1_ClickBefore);
     this.Matrix0                       = ((SAPbouiCOM.Matrix)(this.GetItem("0_U_G").Specific));
     this.Matrix0.ChooseFromListAfter  += new SAPbouiCOM._IMatrixEvents_ChooseFromListAfterEventHandler(this.Matrix0_ChooseFromListAfter);
     this.Matrix1                       = ((SAPbouiCOM.Matrix)(this.GetItem("1_U_G").Specific));
     this.Matrix1.LinkPressedBefore    += new SAPbouiCOM._IMatrixEvents_LinkPressedBeforeEventHandler(this.Matrix1_LinkPressedBefore);
     this.Matrix1.ChooseFromListBefore += new SAPbouiCOM._IMatrixEvents_ChooseFromListBeforeEventHandler(this.Matrix1_ChooseFromListBefore);
     this.Matrix1.ChooseFromListAfter  += new SAPbouiCOM._IMatrixEvents_ChooseFromListAfterEventHandler(this.Matrix1_ChooseFromListAfter);
     this.OnCustomInitialize();
 }
Example #31
0
        private void fillReport()
        {
            SAPbouiCOM.StaticText lblLoading = (SAPbouiCOM.StaticText)oForm.Items.Item("lblLoad").Specific;
            int GoldenColor = 0xFFC908;// System.Drawing.Color.DarkGoldenrod.ToArgb() - 255;
            int redColor    = System.Drawing.Color.Red.R | (System.Drawing.Color.Red.G << 8) | (System.Drawing.Color.Red.B << 16);
            int greenColor  = System.Drawing.Color.Green.R | (System.Drawing.Color.Green.G << 8) | (System.Drawing.Color.Green.B << 16);



            lblLoading.Item.Visible   = true;
            lblLoading.Item.FontSize  = 14;
            lblLoading.Item.BackColor = GoldenColor;
            lblLoading.Item.ForeColor = greenColor;

            oForm.Freeze(true);
            dtRpt.Rows.Clear();
            string strCritaria = " Where (owor.status  <> 'L' and owor.status  <> 'C') ";
            //  strCritaria = " Where 'Y' = 'Y'  ";
            string dtField = "owor.postDate";

            if (opDd.Selected)
            {
                dtField = "owor.DueDate";
            }


            if (txFrom.Value != "" || txTo.Value == "")
            {
                if (txFrom.Value != "")
                {
                    strCritaria += " And " + dtField + " >= '" + txFrom.Value + "'";
                }
                if (txTo.Value != "")
                {
                    strCritaria += " And " + dtField + " <= '" + txTo.Value + "'";
                }
            }
            if (cbPL.Value.ToString().Trim() != "0")
            {
                strCritaria += " And isnull(U_PMX_PLCD,'') = '" + cbPL.Value.ToString() + "'";
            }
            if (txProduct.Value != "")
            {
                strCritaria += " And isnull(owor.itemcode,'') Like  '" + txProduct.Value.ToString() + "%'";
            }
            else
            {
            }
            if (opREL.Selected)
            {
                strCritaria += " and owor.status = 'R' ";
            }


            if (opPL.Selected)
            {
                strCritaria += " and owor.status = 'P' ";
            }

            string strSelect = "Select owor.DocNum as DocNum, case  owor.type when 'S' then 'Standard' when 'P' then 'Special' when 'D' then 'Disassembly' else 'UD' end as Type , case owor.status when 'P' then 'Planned' when 'R' then 'Released' else 'Closed' end as Status,owor.itemcode,oitm.itemname ";

            strSelect += " , owor.postdate, owor.duedate , owor.plannedQty , U_PMX_PLCD , U_B1_Label,U_B1_SEQ, U_B1_FrTxt,isnull(U_B1_DispPos,owor.docentry) as Pos, owor.DocEntry ";
            strSelect += " from owor inner join oitm on oitm.itemcode = owor.itemcode ";

            string strOrderBy = "  order by  case isnull(U_PMX_PLCD,'') when '' then '999' else U_PMX_PLCD end , convert(int, case  isnull(U_B1_SEQ,'') when '' then '99' else  U_B1_SEQ end)";

            System.Data.DataTable sboDtRpt = Program.objHrmsUI.getDataTable(strSelect + strCritaria + strOrderBy, "Open POS");

            int i      = 0;
            int rowCnt = sboDtRpt.Rows.Count;

            if (rowCnt > 0)
            {
                dtRpt.Rows.Add(rowCnt);
            }
            foreach (System.Data.DataRow dr in sboDtRpt.Rows)
            {
                i++;
                string seq = "";
                if (dr["U_B1_SEQ"].ToString() != "")
                {
                    seq = dr["U_B1_SEQ"].ToString();
                }
                dtRpt.SetValue("Id", i - 1, i.ToString());
                dtRpt.SetValue("Type", i - 1, dr["type"].ToString());
                dtRpt.SetValue("DocNum", i - 1, dr["DocNum"].ToString());
                dtRpt.SetValue("OD", i - 1, Convert.ToDateTime(dr["postdate"]));
                dtRpt.SetValue("DueDate", i - 1, Convert.ToDateTime(dr["DueDate"]));
                dtRpt.SetValue("PlannedQty", i - 1, Convert.ToString(dr["PlannedQty"]));

                dtRpt.SetValue("Status", i - 1, dr["Status"].ToString());

                dtRpt.SetValue("ItemCode", i - 1, dr["ItemCode"].ToString());
                dtRpt.SetValue("ItemName", i - 1, dr["ItemName"].ToString());
                dtRpt.SetValue("ProdLine", i - 1, dr["U_PMX_PLCD"].ToString());
                dtRpt.SetValue("Label", i - 1, dr["U_B1_Label"].ToString());

                dtRpt.SetValue("Seq", i - 1, seq);
                dtRpt.SetValue("FreeText", i - 1, dr["U_B1_FrTxt"].ToString());
                dtRpt.SetValue("Pos", i - 1, dr["Pos"].ToString());
                dtRpt.SetValue("DocEntry", i - 1, dr["DocEntry"].ToString());
            }
            mtReport.LoadFromDataSource();

            chApply();

            oForm.Freeze(false);
            lblLoading.Item.Visible = false;

            if (mtReport.RowCount > 0)
            {
                mtReport.SelectRow(1, true, false);
            }
        }