private void OApplication_StatusBarEvent(string Text, BoStatusBarMessageType messageType)
        {
            oApplication.MessageBox(
                string.Format("Evento de Status Bar com mensagem:{ 0}, MessageType:{1}", Text, messageType.ToString())

                , 1, "OK", "", "");
        }
 internal void sapApp_StatusBarEvent(string Text, BoStatusBarMessageType messageType)
 {
     foreach (var e in statusBarEvents)
     {
         ((_IApplicationEvents_StatusBarEventEventHandler)e)(Text, messageType);
     }
 }
Beispiel #3
0
 /// <summary>
 /// Evento que se ejecuta cuando se encuentra un mensaje de status
 /// </summary>
 /// <param name="Text">Texto que se esta mostrando</param>
 /// <param name="messageType">Tipo de mensaje</param>
 private void SBO_Application_StatusBarEvent(string Text, BoStatusBarMessageType messageType)
 {
     try
     {
         if (Text.Contains("No se puede añadir fila") && messageType == BoStatusBarMessageType.smt_Warning)
         {
             if (_Application.Forms.ActiveForm.TypeEx == FRM_TRANSFERENCIA_DE_STOCK.ToString())
             {
                 if (_oForm.Mode == BoFormMode.fm_ADD_MODE)
                 {
                     lDatos.Clear();
                     _oMatrixArticulos = _oForm.Items.Item(GRID_ARTICULOS).Specific;
                     int x = 1;
                     for (int noLinea = 1; noLinea < _oMatrixArticulos.RowCount; noLinea++)
                     {
                         oItemCode = (SAPbouiCOM.EditText)_oMatrixArticulos.Columns.Item(COLUMNA_CLAVE_ARTICULO).Cells.Item(noLinea).Specific;
                         if (oItemCode.Value.Substring(0, 2).ToString() == "PL")
                         {
                             oSerieInicio = (SAPbouiCOM.EditText)_oMatrixArticulos.Columns.Item(COLUMNA_SERIE_INICIO).Cells.Item(noLinea).Specific;
                             oSerieFin    = (SAPbouiCOM.EditText)_oMatrixArticulos.Columns.Item(COLUMNA_SERIE_FIN).Cells.Item(noLinea).Specific;
                             oSerie       = (SAPbouiCOM.EditText)_oMatrixArticulos.Columns.Item(COLUMNA_SERIE).Cells.Item(noLinea).Specific;
                             if (!string.IsNullOrEmpty(oSerieInicio.Value.ToString()) && !string.IsNullOrEmpty(oSerieFin.Value.ToString()))
                             {
                                 itemDatos            = new Datos();
                                 itemDatos.itemCode   = oItemCode.Value.ToString();
                                 itemDatos.serieInial = oSerieInicio.Value.ToString();
                                 itemDatos.serieFinal = oSerieFin.Value.ToString();
                                 itemDatos.noLinea    = x;
                                 lDatos.Add(itemDatos);
                                 x += 1;
                             }
                             else if (!string.IsNullOrEmpty(oSerie.Value.ToString()))
                             {
                                 itemDatos            = new Datos();
                                 itemDatos.itemCode   = oItemCode.Value.ToString();
                                 itemDatos.serieInial = oSerie.Value.ToString();
                                 itemDatos.serieFinal = oSerie.Value.ToString();
                                 itemDatos.noLinea    = x;
                                 lDatos.Add(itemDatos);
                                 x += 1;
                             }
                         }
                     }
                     if (lDatos.Count != 0)
                     {
                         Addon.Instance.Ejecutaclase("25", lDatos);
                     }
                 }
             }
         }
     }
     catch (Exception ex)
     {
         _Application.MessageBox("Error en StatusBarEvent *clsTransferenciaDeStock* : " + ex.Message);
     }
 }
Beispiel #4
0
        public static void SetText(string msg, BoMessageTime time = BoMessageTime.bmt_Medium, BoStatusBarMessageType tipo = BoStatusBarMessageType.smt_Error, Assembly pAssembly = null)
        {
            try
            {
                if (pAssembly == null)
                {
                    pAssembly = Assembly.GetCallingAssembly();
                }

                B1Connections.theAppl.StatusBar.SetText(string.Format("[{0}] {1}", pAssembly.GetName().Name, msg), time, tipo);
            }
            catch (Exception e)
            {
                Helpers.SetText(string.Format("Helpers.SetText - {0}", e.Message));
            }
        }
Beispiel #5
0
        private void DisplayMessage(BoStatusBarMessageType messageType)
        {
            var message = string.Format(text, args);

            application.StatusBar.SetSystemMessage(message, BoMessageTime.bmt_Short, messageType);
        }
Beispiel #6
0
 public void statusMsg(string strMessage, BoStatusBarMessageType msgType = BoStatusBarMessageType.smt_None)
 {
     oApplication.StatusBar.SetText(Text: strMessage, Type: msgType);
 }
Beispiel #7
0
 public void StatusBar(string Text, BoMessageTime Seconds, BoStatusBarMessageType Type)
 {
     throw new NotImplementedException();
 }
Beispiel #8
0
 public void SBO_Application_StatusBarEvent(string Text, SAPbobsCOM.Company sbo_company, ref Application sbo_application, BoStatusBarMessageType messageType)
 {
 }
        internal static void SetTextOnStatusBar(this Form owner, string message, BoStatusBarMessageType messageType, params object[] param)
        {
            var messageTest = string.Format(message, param);

            owner.SetTextOnStatusBar(messageTest, BoMessageTime.bmt_Short, messageType);
        }
Beispiel #10
0
 /// <summary>
 /// Inser uma nova mensagem na barra de status
 /// </summary>
 /// <param name="text">Texto</param>
 /// <param name="seconds">Tempo</param>
 /// <param name="type">Tipo de Alerta</param>
 public void SetTextOnStatusBar(string text, BoMessageTime seconds, BoStatusBarMessageType type)
 {
     m_Concrete.StatusBar(text, seconds, type);
 }
 public static void StatusBarEvent(String Text, BoStatusBarMessageType MessageType)
 {
 }
Beispiel #12
0
 /// <summary>
 /// Exibe um texto na parte debaixo da tela do SAP (Status bar)
 /// </summary>
 /// <param name="text">Texto que deseja exibir</param>
 /// <param name="seconds">tempo de exibição</param>
 /// <param name="type">Tipo de Mensagem</param>
 public void SetTextOnStatusBar(string text, BoMessageTime seconds = BoMessageTime.bmt_Short, BoStatusBarMessageType type = BoStatusBarMessageType.smt_Error)
 {
     Application.GetInstance().SetTextOnStatusBar(text, seconds, type);
 }
Beispiel #13
0
 internal void sapApp_StatusBarEvent(string Text, BoStatusBarMessageType messageType)
 {
     foreach (var e in statusBarEvents)
     {
         ((_IApplicationEvents_StatusBarEventEventHandler)e)(Text, messageType);
     }
 }