Exemplo n.º 1
0
 // boton buscar para ejecutar el filtro deseado u seleccionado
 private void button1_Click(object sender, EventArgs e)
 {
     //Consulta cual tabPage esta selecionada para aplicarle el filtro seleccionado
     if (tab_TablasLog.SelectedTab == tabp_LogServicoEmail)
     {
         //verifica cual de las 2 opciones de friltro esta selecionada y al precionar el boton buscar carga el stored procedure correspondiente
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioEmail.DataSource = ClaseLogServicioMail.Carga24hrs_ServicioMail();
             grdv_LogServicioEmail.Refresh();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioEmail.DataSource = ClaseLogServicioMail.Carga1000_ServicioMail();
             grdv_LogServicioEmail.Refresh();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioReplicaCD)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioReplicaCD.DataSource = ClaseLogServicioReplicaCD.Carga24hrs_ServicioReplicaCD();
             grdv_LogServicioReplicaCD.Refresh();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioReplicaCD.DataSource = ClaseLogServicioReplicaCD.Carga1000_ServicioReplicaCD();
             grdv_LogServicioReplicaCD.Refresh();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioWMSSAP)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioWMSSAP.DataSource = ClaseLogServicioWMSSAP.Carga24hrs();
             grdv_LogServicioWMSSAP.Refresh();
             grdv_LogServicioWMSSAP.Update();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioWMSSAP.DataSource = ClaseLogServicioWMSSAP.Carga1000();
             grdv_LogServicioWMSSAP.Refresh();
             grdv_LogServicioWMSSAP.Update();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioServInfo)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
         }
     }
 }
Exemplo n.º 2
0
 private void buscar()
 {
     //Consulta cual tabPage esta selecionada para aplicarle el filtro seleccionado
     if (tab_TablasLog.SelectedTab == tabp_LogServicoEmail)
     {
         //verifica cual de las 3 opciones de friltro esta selecionada y al precionar el boton buscar carga el stored procedure correspondiente
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioEmail.DataSource = ClaseLogServicioMail.Carga24hrs_ServicioMail();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioEmail.DataSource = ClaseLogServicioMail.Carga1000_ServicioMail();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioEmail.DataSource = ClaseLogServicioMail.CargaLogError_ServicoMail();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioReplicaCD)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioReplicaCD.DataSource = ClaseLogServicioReplicaCD.Carga24hrs_ServicioReplicaCD();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioReplicaCD.DataSource = ClaseLogServicioReplicaCD.Carga1000_ServicioReplicaCD();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioReplicaCD.DataSource = ClaseLogServicioReplicaCD.CargaLogError_ServicoReplicaCD();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioWMSSAP)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioWMSSAP.DataSource = ClaseLogServicioWMSSAP.Carga24hrs();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioWMSSAP.DataSource = ClaseLogServicioWMSSAP.Carga1000();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioWMSSAP.DataSource = ClaseLogServicioWMSSAP.CargaLogError();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioWMSOleada)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioWMSOleada.DataSource = ClaseLogServicioWMSOleada.carga24hrs_ServicioWMNSOleada();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioWMSOleada.DataSource = ClaseLogServicioWMSOleada.Carga1000_ServicioWMSOleada();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioWMSOleada.DataSource = ClaseLogServicioWMSOleada.CargaLogError_ServicioWMSOleada();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioServInfo)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioServInfo.DataSource = ClaseLogServicioServInfo.Carga24hrs_ServicioServInfo();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioServInfo.DataSource = ClaseLogServicioServInfo.Carga1000_ServicioServInfo();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioServInfo.DataSource = ClaseLogServicioServInfo.CargaLogError_ServicioServInfo();
         }
     }
     else if (tab_TablasLog.SelectedTab == tabp_LogServicioSmartphone)
     {
         if (rdo_ErroresUltimas24Hrs.Checked == true)
         {
             grdv_LogServicioSmartphone.DataSource = ClaseLogServicioSmartphone.Carga24hrs_ServicioSmartphone();
         }
         else if (rdo_Ultimos1000Errores.Checked == true)
         {
             grdv_LogServicioSmartphone.DataSource = ClaseLogServicioSmartphone.Carga1000_ServicioSmartphone();
         }
         else if (rdo_Default.Checked == true)
         {
             grdv_LogServicioSmartphone.DataSource = ClaseLogServicioSmartphone.CargaLogError_ServicioSmartphone();
         }
     }
 }