public insertLugarDiligencia ( |
||
oENTLugarDiligencia | ||
return |
private void insertLugarDiligencia() { BPLugarDiligencia oBPLugarDiligencia = new BPLugarDiligencia(); ENTLugarDiligencia oENTLugarDiligencia = new ENTLugarDiligencia(); ENTResponse oENTResponse = new ENTResponse(); try { // Formilario oENTLugarDiligencia.Nombre = this.txtActionNombre.Text.Trim(); oENTLugarDiligencia.Descripcion = this.txtActionDescripcion.Text.Trim(); // Transacción oENTResponse = oBPLugarDiligencia.insertLugarDiligencia(oENTLugarDiligencia); // Validaciones if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); } if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); } // Transacción exitosa ClearActionPanel(); // Actualizar Grid selectLugarDiligencia(); // Mensaje al usuario ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('Lugar creado con éxito!'); focusControl('" + this.txtNombre.ClientID + "');", true); } catch (Exception ex) { throw (ex); } }