private void InsertarAsignaTCombustible() { CLS_Activos_TCombustible Clase = new CLS_Activos_TCombustible(); if (TarjetaSelect.Length > 0) { Clase.Id_Tarjeta_Combustibleold = TarjetaSelect; } else { Clase.Id_Tarjeta_Combustibleold = textTCombustible.Text.Trim(); } Clase.Id_Tarjeta_Combustible = textTCombustible.Text.Trim(); Clase.Id_Activo = IdActivo; Clase.MtdInsertarActivos_TCombustible(); if (Clase.Exito) { CargarAsignaTCombustible(); XtraMessageBox.Show("Se ha Insertado el registro con exito"); LimpiarCampos(); } else { XtraMessageBox.Show(Clase.Mensaje); } }
private void CargarAsignaTCombustible() { gridControl1.DataSource = null; CLS_Activos_TCombustible Clase = new CLS_Activos_TCombustible(); Clase.Id_Activo = IdActivo; Clase.MtdSeleccionarActivos_TCombustible(); if (Clase.Exito) { gridControl1.DataSource = Clase.Datos; } }
private void EliminarAsignaTCombustible() { CLS_Activos_TCombustible Clase = new CLS_Activos_TCombustible(); Clase.Id_Tarjeta_Combustible = textTCombustible.Text.Trim(); Clase.Id_Activo = IdActivo; Clase.MtdEliminarActivos_TCombustible(); if (Clase.Exito) { CargarAsignaTCombustible(); XtraMessageBox.Show("Se ha Eliminado el registro con exito"); LimpiarCampos(); } else { XtraMessageBox.Show(Clase.Mensaje); } }