void SelectMedioComunicacion()
        {
            BPMedioComunicacion oBPMedioComunicacion = new BPMedioComunicacion();
            ENTResponse oENTResponse = new ENTResponse();
            ENTMedioComunicacion oENTMedioComunicacion = new ENTMedioComunicacion();

            try
            {

                //Transacción
                oENTResponse = oBPMedioComunicacion.searchcatMedioComunicacion(oENTMedioComunicacion);

                //Validación
                if (oENTResponse.GeneratesException) { throw new Exception(oENTResponse.sErrorMessage); }
                if (oENTResponse.sMessage != "") { throw new Exception(oENTResponse.sMessage); }

                // Bind
                this.ddlMedioComunicacion.DataTextField = "Nombre";
                this.ddlMedioComunicacion.DataValueField = "MedioComunicacionId";
                this.ddlMedioComunicacion.DataSource = oENTResponse.dsResponse.Tables[1];
                this.ddlMedioComunicacion.DataBind();

                // Item extra
                this.ddlMedioComunicacion.Items.Insert(0, new ListItem("[Seleccione]", "0"));

            }catch (Exception ex){
                ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + gcJavascript.ClearText(ex.Message) + "');", true);
            }
        }
        private void selectMedioComunicacion_ForEdit(Int32 MedioComunicacionId)
        {
            BPMedioComunicacion oBPMedioComunicacion = new BPMedioComunicacion();
            ENTMedioComunicacion oENTMedioComunicacion = new ENTMedioComunicacion();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTMedioComunicacion.MedioComunicacionId = MedioComunicacionId;
                oENTMedioComunicacion.Nombre = this.txtActionNombre.Text.Trim();

                // Transacción
                oENTResponse = oBPMedioComunicacion.selectcatMedioComunicacion(oENTMedioComunicacion);

                // Validaciones
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                this.lblActionMessage.Text = oENTResponse.sMessage;

                // Llenado de controles
                this.txtActionNombre.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Nombre"].ToString();
                this.txtActionDescripcion.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Descripcion"].ToString();

            }
            catch (Exception ex) { throw (ex); }
        }
        private void updateMedioComunicacion(Int32 MedioComunicacionId)
        {
            BPMedioComunicacion oBPMedioComunicacion = new BPMedioComunicacion();
            ENTMedioComunicacion oENTMedioComunicacion = new ENTMedioComunicacion();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTMedioComunicacion.MedioComunicacionId = MedioComunicacionId;
                oENTMedioComunicacion.Nombre = this.txtActionNombre.Text.Trim();
                oENTMedioComunicacion.Descripcion = this.txtActionDescripcion.Text.Trim();

                // Transacción
                oENTResponse = oBPMedioComunicacion.updatecatMedioComunicacion(oENTMedioComunicacion);

                // Validaciones
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Transacción exitosa
                ClearActionPanel();

                // Actualizar grid
                selectMedioComunicacion();

                // Mensaje de usuario
                ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('Información actualizada con éxito!'); focusControl('" + this.txtNombre.ClientID + "');", true);

            }
            catch (Exception ex) { throw (ex); }
        }
        private void selectMedioComunicacion()
        {
            BPMedioComunicacion oBPMedioComunicacion = new BPMedioComunicacion();
            ENTMedioComunicacion oENTMedioComunicacion = new ENTMedioComunicacion();
            ENTResponse oENTResponse = new ENTResponse();

            String sMessage = "";

            try
            {

                // Formulario
                oENTMedioComunicacion.Nombre = this.txtNombre.Text.Trim();

                // Transacción
                oENTResponse = oBPMedioComunicacion.selectcatMedioComunicacion(oENTMedioComunicacion);

                // Validaciones
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { sMessage = "alert('" + oENTResponse.sMessage + "');"; }

                // Llenado de controles
                this.gvMedioComunicacion.DataSource = oENTResponse.dsResponse.Tables[1];
                this.gvMedioComunicacion.DataBind();

                // Mensaje al usuario
                ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), sMessage, true);

            }
            catch (Exception ex) { throw (ex); }
        }