예제 #1
0
    protected void RegistroDeUsuarioForm_CreatedUser(object sender, EventArgs e)
    {
        MembershipUser membershipUser = Membership.GetUser(RegistroDeUsuarioForm.Email);

        if (membershipUser != null)
        {
            //YA NO LO LOGEAMOS DE FORMA AUTOMÁTICA
            //FormsAuthentication.SetAuthCookie(RegistroDeUsuarioForm.UserName, false);
            using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
            {
                if (membershipUser.ProviderUserKey != null)
                {
                    objUsuario.userid = Convert.ToInt32(membershipUser.ProviderUserKey);
                    TextBox txtFirstName = (TextBox)RegistroDeUsuarioForm.CreateUserStep.ContentTemplateContainer.FindControl("txtFirstName");
                    if (txtFirstName != null)
                    {
                        objUsuario.nombre = txtFirstName.Text;
                    }
                    TextBox txtLastName = (TextBox)RegistroDeUsuarioForm.CreateUserStep.ContentTemplateContainer.FindControl("txtLastName");
                    if (txtLastName != null)
                    {
                        objUsuario.apellidos = txtLastName.Text;
                    }
                    if (objUsuario.bModificar())
                    {
                        EnviarMensajeAdministradores(RegistroDeUsuarioForm.Email);
                        EnviarMensajeUsuario(RegistroDeUsuarioForm.Email);
                    }
                    Response.Redirect("~/novalidated.aspx?userid=" + objUsuario.userid.Value.ToString());
                }
            }
        }
    }
예제 #2
0
    private void EnviarMensajeUsuario(string EmailUsuario)
    {
        string validationCode = new Random().Next().ToString();

        //1.-Destino del mensaje
        System.Net.Mail.MailAddressCollection MisDestinos = new System.Net.Mail.MailAddressCollection();
        MisDestinos.Add(new System.Net.Mail.MailAddress(EmailUsuario));

        //2.-Cuerpo del mensaje
        HttpServerUtility server   = HttpContext.Current.Server;
        string            sMensaje = "We have sucessfully received your registration request to DropKeys. To complete the subscription process, please click the following link :\r\n\r\n " + Request.Url.GetLeftPart(UriPartial.Authority) + "/validatecode.aspx?email=" +
                                     server.UrlEncode(EmailUsuario) + "&vc=" + validationCode + "\r\n\r\nThank you.";

        if (EmailUtils.SendMessageEmail(MisDestinos, "Verify your email", sMensaje))
        {
            using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
            {
                MembershipUser Usuario = Membership.GetUser(EmailUsuario, false);
                objUsuario.userid = Convert.ToInt32(Usuario.ProviderUserKey);
                if (objUsuario.bConsultar())
                {
                    objUsuario.mensaje_validacion = true;
                    objUsuario.validado           = false;
                    objUsuario.codigo_validacion  = validationCode;
                    objUsuario.bModificar();
                }
            }
        }
    }
예제 #3
0
 protected void btnSaveDataProfile_Click(object sender, EventArgs e)
 {
     if (this.iduser.HasValue)
     {
         using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
         {
             objUsuario.userid = this.iduser;
             if (objUsuario.bConsultar())
             {
                 if (!string.IsNullOrEmpty(txtFirstName.Text))
                 {
                     objUsuario.nombre = txtFirstName.Text;
                 }
                 if (!string.IsNullOrEmpty(txtLastName.Text))
                 {
                     objUsuario.apellidos = txtLastName.Text;
                 }
                 if (!string.IsNullOrEmpty(txtResume.Text))
                 {
                     objUsuario.resumen = txtResume.Text;
                 }
                 if (objUsuario.bModificar())
                 {
                     RellenaDatosPerfil();
                 }
                 else
                 {
                     RegistraIncidencia("registrado_profile", "Error en la función << btnSaveDataProfile_Click() >>. Motivo : No se ha podido MODIFICAR el perfil del usuario", 4);
                 }
             }
             else
             {
                 Response.Redirect("~/errors/notfound.aspx");
             }
         }
     }
     else
     {
         Response.Redirect("~/errors/notfound.aspx");
     }
 }
    private void RellenaInfoUsuario()
    {
        MembershipUser usr = Membership.GetUser();

        if (usr != null)
        {
            try
            {
                using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
                {
                    objUsuario.userid = Convert.ToInt32(usr.ProviderUserKey);
                    if (objUsuario.bConsultar())
                    {
                        if ((!string.IsNullOrEmpty(objUsuario.apellidos)) && (!string.IsNullOrEmpty(objUsuario.nombre)))
                        {
                            lbNombreUsuario.Text = objUsuario.apellidos + ", " + objUsuario.nombre;
                        }
                        else if (!string.IsNullOrEmpty(objUsuario.apellidos))
                        {
                            lbNombreUsuario.Text = objUsuario.apellidos;
                        }
                        else if (!string.IsNullOrEmpty(objUsuario.nombre))
                        {
                            lbNombreUsuario.Text = objUsuario.nombre;
                        }
                        imgProfileUser.ImageUrl = objUsuario.imageurl;
                    }
                }
            }
            catch (Exception excp)
            {
                ExceptionUtility.LogException(excp, "Error en la función << RellenaDimensiones() >>");
            }
        }
        else
        {
            Response.Redirect("~/errors/notfound.aspx");
        }
    }
예제 #5
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         if (!string.IsNullOrEmpty(Request.QueryString["userid"]))
         {
             using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
             {
                 objUsuario.userid = Convert.ToInt32(Request.QueryString["userid"]);
                 if (objUsuario.bConsultar())
                 {
                     this.usuarioid          = objUsuario.userid;
                     lbFirstAndLastName.Text = objUsuario.nombre + " " + objUsuario.apellidos;
                 }
                 else
                 {
                     Response.Redirect("~/errors/notfound.aspx");
                 }
             }
         }
     }
 }
예제 #6
0
    protected void btnSendCode_Click(object sender, EventArgs e)
    {
        if (!usuarioid.HasValue)
        {
            return;
        }

        MembershipUser Usuario = Membership.GetUser(usuarioid, false);

        if (Usuario != null)
        {
            string validationCode = new Random().Next().ToString();

            //1.-Destino del mensaje
            System.Net.Mail.MailAddressCollection MisDestinos = new System.Net.Mail.MailAddressCollection();
            MisDestinos.Add(new System.Net.Mail.MailAddress(Usuario.Email));

            //2.-Cuerpo del mensaje
            HttpServerUtility server   = HttpContext.Current.Server;
            string            sMensaje = "We have sucessfully received your registration request to DropKeys. To complete the subscription process, please click the following link :\r\n\r\n " + Request.Url.GetLeftPart(UriPartial.Authority) + "/validatecode.aspx?email=" +
                                         server.UrlEncode(Usuario.Email) + "&vc=" + validationCode + "\r\n\r\nThank you.";

            if (EmailUtils.SendMessageEmail(MisDestinos, "Verify your email", sMensaje))
            {
                using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
                {
                    objUsuario.userid = usuarioid;
                    if (objUsuario.bConsultar())
                    {
                        objUsuario.mensaje_validacion = true;
                        objUsuario.validado           = false;
                        objUsuario.codigo_validacion  = validationCode;
                        objUsuario.bModificar();
                    }
                }
            }
        }
    }
예제 #7
0
    private void RellenaIndicador()
    {
        if (this.idindicator.HasValue)
        {
            using (Clases.cKPI_INDICATORS objIndicador = new Clases.cKPI_INDICATORS())
            {
                objIndicador.indicatorid = this.idindicator.Value;
                hdnIndicatorID.Value     = objIndicador.indicatorid.ToString();
                if (objIndicador.bConsultar())
                {
                    //********************************************
                    //  RELLENAMOS LOS DATOS BÁSICOS DEL INDICADOR
                    //********************************************
                    lbTitulo.Text        = objIndicador.titulo;
                    txtNombre.Text       = objIndicador.titulo;
                    txtTituloValue.Text  = objIndicador.titulo;
                    txtResumen.Text      = objIndicador.resumen;
                    txtResumenValue.Text = objIndicador.resumen;
                    if (!string.IsNullOrEmpty(objIndicador.descripcion))
                    {
                        txtDescripcion.Text      = objIndicador.descripcion;
                        txtDescripcionValue.Text = objIndicador.descripcion;
                    }
                    else
                    {
                        txtDescripcion.Text = "We are sorry but there is currently no description available.<br/><br/>";
                    }
                    if (objIndicador.fecha_alta.HasValue)
                    {
                        lbFechaAlta.Text = objIndicador.fecha_alta.Value.ToString("dd MMMM, yyyy", new System.Globalization.CultureInfo("en-US")) + " (" + CalculaFechaDesdeCuando(objIndicador.fecha_alta.Value) + ")";
                    }
                    else
                    {
                        lbFechaAlta.Text = "--undefined--";
                    }
                    lbUnidad.Text        = objIndicador.unidad + " (" + objIndicador.simbolo + ")";
                    txtUnidadValue.Text  = objIndicador.unidad;
                    txtSimboloValue.Text = objIndicador.simbolo;
                    lbAgregacion.Text    = objIndicador.funcion_agregada_desc;
                    cmbFuncionAgregadaValue.SelectedValue = objIndicador.funcion_agregada;
                    if (objIndicador.RatingValues.HasValue)
                    {
                        targetout.Attributes.Add("data-score", objIndicador.RatingValues.Value.ToString());
                    }
                    if (!string.IsNullOrEmpty(objIndicador.imageurl))
                    {
                        imgIndicador.ImageUrl = objIndicador.imageurl;
                    }
                    else
                    {
                        imgIndicador.ImageUrl = "~/images/indicators/no-image.jpg";
                    }
                    if (objIndicador.subcategoryid.HasValue)
                    {
                        using (Clases.cKPI_SUBCATEGORIES objSubcategorias = new Clases.cKPI_SUBCATEGORIES())
                        {
                            objSubcategorias.subcategoryid = objIndicador.subcategoryid;
                            if (objSubcategorias.bConsultar())
                            {
                                lbSubcategoria.Text = objSubcategorias.nombre;
                            }
                            else
                            {
                                lbSubcategoria.Text = "-- unspecified --";
                            }
                        }
                    }
                    else
                    {
                        lbSubcategoria.Text = "-- unspecified --";
                    }

                    if (User.Identity.IsAuthenticated)
                    {
                        MembershipUser usr = Membership.GetUser();
                        if (usr != null)
                        {
                            HyperLink lbCreatorUserName        = (HyperLink)LoginViewCreatorUser.FindControl("lbCreatorUserName");
                            Panel     PanelIndicadorAusente    = (Panel)LoginViewIndicador.FindControl("PanelIndicadorAusente");
                            Panel     PanelIndicadorPrivado    = (Panel)LoginViewIndicador.FindControl("PanelIndicadorPrivado");
                            Panel     PanelIndicadorCompartido = (Panel)LoginViewIndicador.FindControl("PanelIndicadorCompartido");

                            btnImportarExcel.PostBackUrl = "~/registrado/importxls.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            btnImportarCsv.PostBackUrl   = "~/registrado/importcsv.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            btnImportarJson.PostBackUrl  = "~/registrado/importjson.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            btnImportarXML.PostBackUrl   = "~/registrado/importxml.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            btnImportarTabla.PostBackUrl = "~/registrado/importtable.aspx?indicatorid=" + this.idindicator.Value.ToString();

                            LinkButton btnCompartir = (LinkButton)LoginViewIndicador.FindControl("btnCompartir");
                            if (btnCompartir != null)
                            {
                                btnCompartir.PostBackUrl = "~/registrado/sharekpi.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            }
                            LinkButton btnCompartir2 = (LinkButton)LoginViewIndicador.FindControl("btnCompartir2");
                            if (btnCompartir2 != null)
                            {
                                btnCompartir2.PostBackUrl = "~/registrado/sharekpi.aspx?indicatorid=" + this.idindicator.Value.ToString();
                            }

                            using (Clases.cKPI_INDICATOR_USERS objIndicadorusuario = new Clases.cKPI_INDICATOR_USERS())
                            {
                                objIndicadorusuario.indicatorid = this.idindicator.Value;
                                objIndicadorusuario.userid      = objIndicador.userid;
                                if (objIndicadorusuario.bConsultar())
                                {
                                    if (objIndicadorusuario.anonimo)
                                    {
                                        lbCreatorUserName.Text = "-- Anonymous --";
                                    }
                                    else
                                    {
                                        using (Clases.cASPNET_INFO_USUARIO objUsuarioCreador = new Clases.cASPNET_INFO_USUARIO())
                                        {
                                            objUsuarioCreador.userid = objIndicador.userid;
                                            if (objIndicador.userid != Convert.ToInt32(usr.ProviderUserKey))
                                            {
                                                lbCreatorUserName.Attributes.Add("data-userid", objIndicador.userid.Value.ToString());
                                            }
                                            if (objUsuarioCreador.bConsultar())
                                            {
                                                lbCreatorUserName.Text = objUsuarioCreador.apellidos + ", " + objUsuarioCreador.nombre;
                                            }
                                            else
                                            {
                                                lbCreatorUserName.Text = "-- unspecified --";
                                            }
                                        }
                                    }
                                }
                            }
                            if (objIndicador.userid != Convert.ToInt32(usr.ProviderUserKey))
                            {
                                PanelChangeImage.Visible = false;
                            }
                            else
                            {
                                PanelChangeImage.Visible = true;
                            }

                            if (!objIndicador.compartido)
                            {
                                //El indicador aún no lo hemos compartido con el resto
                                PanelSocialMedia.Visible         = false;
                                PanelIndicadorCompartido.Visible = false;
                                PanelIndicadorPrivado.Visible    = true;
                                PanelComentarios.Visible         = false;
                                lbSubcategoria.Text = "Private";

                                datasetsItem.Visible             = true;
                                dimensionsItem.Visible           = true;
                                ArtDimensions.Visible            = true;
                                ArtDataSets.Visible              = true;
                                PanelIndicadorAusente.Visible    = false;
                                PanelEtiquetasNoEditable.Visible = false;
                                PanelEtiquetasEditable.Visible   = true;
                                RellenaEtiquetasEditables();
                                RellenaAtributos();
                                RellenaDatasets();
                                RellenaImports();
                            }
                            else
                            {
                                //Se trata de un indicador compartido
                                using (Clases.cKPI_INDICATOR_USERS objIndicadorusuario = new Clases.cKPI_INDICATOR_USERS())
                                {
                                    objIndicadorusuario.indicatorid = this.idindicator.Value;
                                    objIndicadorusuario.userid      = Convert.ToInt32(usr.ProviderUserKey);
                                    //LO TIENE AÑADIDO A SU BIBLIOTECA
                                    if (objIndicadorusuario.bConsultar())
                                    {
                                        othersourcesItem.Visible         = true;
                                        datasetsItem.Visible             = true;
                                        dimensionsItem.Visible           = true;
                                        ArtOtherSources.Visible          = true;
                                        ArtDimensions.Visible            = true;
                                        ArtDataSets.Visible              = true;
                                        PanelIndicadorAusente.Visible    = false;
                                        PanelEtiquetasNoEditable.Visible = false;
                                        PanelEtiquetasEditable.Visible   = true;
                                        RellenaEtiquetasEditables();
                                        RellenaOtherSources();
                                        RellenaRevisiones();
                                        RellenaAtributos();
                                        RellenaDatasets();
                                        RellenaImports();
                                        RellenaAmistades();
                                        RellenaFormulas();

                                        //Incrementamos el número de visitas
                                        objIndicadorusuario.visitas = objIndicadorusuario.visitas + 1;
                                        objIndicadorusuario.bModificarVisitas();

                                        PanelAnonimo.Visible     = true;
                                        PanelSocialMedia.Visible = true;

                                        PanelIndicadorPrivado.Visible    = false;
                                        PanelIndicadorCompartido.Visible = true;
                                        if (objIndicadorusuario.anonimo)
                                        {
                                            cbIsAnonymnous.Checked = true;
                                            lbIsAnonymousHelp.Text = "Only your friends would be able to see your profile";
                                        }
                                        else
                                        {
                                            cbIsAnonymnous.Checked = false;
                                            lbIsAnonymousHelp.Text = "Everybody would be able to see your profile";
                                        }


                                        using (Clases.cKPI_INDICATOR_REVISIONS objRevision = new Clases.cKPI_INDICATOR_REVISIONS())
                                        {
                                            if (objIndicador.userid == Convert.ToInt32(usr.ProviderUserKey))
                                            {
                                                //Yo soy el responsable del indicador
                                                objRevision.indicatorid      = this.idindicator;
                                                PanelPendingRevision.Visible = false;
                                                if (objRevision.nRecuento() > 0)
                                                {
                                                    revisionItem.Visible = true;
                                                    ArtRevisions.Visible = true;
                                                    PanelAccetpOrCancelRevision.Visible = true;
                                                }
                                                else
                                                {
                                                    revisionItem.Visible = false;
                                                    ArtRevisions.Visible = false;
                                                    PanelAccetpOrCancelRevision.Visible = false;
                                                }
                                            }
                                            else
                                            {
                                                //El responsable del indicador es otra persona
                                                objRevision.indicatorid             = this.idindicator;
                                                objRevision.userid                  = Convert.ToInt32(usr.ProviderUserKey);
                                                PanelAccetpOrCancelRevision.Visible = false;
                                                if (objRevision.nRecuento() > 0)
                                                {
                                                    PanelPendingRevision.Visible = true;
                                                }
                                                else
                                                {
                                                    PanelPendingRevision.Visible = false;
                                                }
                                            }
                                        }
                                    }
                                    else
                                    {
                                        PanelIndicadorPrivado.Visible    = false;
                                        PanelIndicadorCompartido.Visible = false;
                                        PanelIndicadorAusente.Visible    = true;
                                    }
                                }
                            }
                        }
                    }
                }
                else
                {
                    Response.Redirect("~/errors/notfound.aspx");
                }
            }
        }
        else
        {
            Response.Redirect("~/errors/notfound.aspx");
        }
    }
예제 #8
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            string email = string.Empty;
            string vc    = string.Empty;

            if (!string.IsNullOrEmpty(Request.QueryString["email"]))
            {
                email = Request.QueryString["email"].ToString();
            }

            if (!string.IsNullOrEmpty(Request.QueryString["vc"]))
            {
                vc = Request.QueryString["vc"].ToString();
            }

            // Validate this email and validation code
            if (string.IsNullOrEmpty(email))
            {
                lbResultado.Text     = "<div class='alert alert-danger fade in'>Sorry but the e-mail user " + email + " can't be found in our database</div>";
                btnGoWebsite.Visible = false;
            }
            else if (string.IsNullOrEmpty(vc))
            {
                // Send email for validation
                MembershipUser Usuario = Membership.GetUser(email, false);
                using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
                {
                    objUsuario.userid   = Convert.ToInt32(Usuario.ProviderUserKey);
                    objUsuario.validado = true;
                    if (objUsuario.bConsultar())
                    {
                        //GREEN
                        lbResultado.Text = "<div class='alert alert-success fade in'>The e-mail user " + email + " has already been successfully validated, it is not necessary re-validate it again.</div>";
                    }
                    else
                    {
                        try
                        {
                            string validationCode = new Random().Next().ToString();

                            //1.-Destino del mensaje
                            System.Net.Mail.MailAddressCollection MisDestinos = new System.Net.Mail.MailAddressCollection();
                            MisDestinos.Add(new System.Net.Mail.MailAddress(email));

                            //2.-Cuerpo del mensaje
                            HttpServerUtility server   = HttpContext.Current.Server;
                            string            sMensaje = "We have received your registration request to DropKeys. To complete the subscription process, please click the following link:\r\n\r\n " + Request.Url.GetLeftPart(UriPartial.Authority) + "/validatecode.aspx?email=" +
                                                         server.UrlEncode(email) + "&vc=" + validationCode +
                                                         "\r\n\r\nThank you.";

                            if (EmailUtils.SendMessageEmail(MisDestinos, "Check your email", sMensaje))
                            {
                                objUsuario.userid             = Convert.ToInt32(Usuario.ProviderUserKey);
                                objUsuario.mensaje_validacion = true;
                                objUsuario.validado           = false;
                                objUsuario.codigo_validacion  = validationCode;
                                objUsuario.suscrito           = false;
                                objUsuario.bModificar();

                                lbResultado.Text = "<div class='alert alert-success fade in'>We have sent an e-mail to " + email + ". Please click on the link enclosed in the mail to complete the subscription process.</div>";
                            }
                            else
                            {
                                //RED
                                lbResultado.Text = "<div class='alert alert-danger fade in'>We are very sorry we were unable to send the email with the validation key <a href=\"validatecode.aspx?email=" + Server.UrlEncode(email) + "\">Press here</a> to try it again.</div>";
                            }
                        }
                        catch (Exception)
                        {
                            //RED
                            lbResultado.Text = "<div class='alert alert-danger fade in'>We are very sorry we were unable to send the email with the validation key <a href=\"validatecode.aspx?email=" + Server.UrlEncode(email) + "\">Press here</a> to try it again.</div>";
                        }
                    }
                }
            }
            else if (!string.IsNullOrEmpty(vc))
            {
                MembershipUser Usuario = Membership.GetUser(email, false);
                using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
                {
                    objUsuario.userid            = Convert.ToInt32(Usuario.ProviderUserKey);
                    objUsuario.codigo_validacion = vc;
                    if (objUsuario.bConsultar())
                    {
                        //GREEN
                        lbResultado.Text    = "<div class='alert alert-success fade in'>Congratulations, the e-mail " + email + " has been successfully validated.</div>";
                        objUsuario.validado = true;
                        objUsuario.suscrito = true;
                        objUsuario.bModificar();

                        //Logeamos
                        FormsAuthentication.SetAuthCookie(email, true);
                    }
                    else
                    {
                        //RED
                        lbResultado.Text = "<div class='alert alert-danger fade in'>Sorry but the email " + email + " could not be validated by our system. The validation code provided is not correct. " +
                                           "<a href=\"validatecode.aspx?email=" + email + "\">Click here</a>" + " to request a new validation code.</div>";
                    }
                }
            }
        }
    }
예제 #9
0
    private void RellenaDatosPerfil()
    {
        if (this.iduser.HasValue)
        {
            MembershipUser usr = Membership.GetUser(this.iduser);
            try
            {
                lbFechaDeAltaUsuario.Text  = CalculaFechaDesdeCuando(usr.CreationDate);
                lbUltimoAccesoUsuario.Text = CalculaFechaDesdeCuando(usr.LastActivityDate);
                lbEmailUsuario.Text        = usr.Email;
            }
            catch (Exception excp)
            {
                ExceptionUtility.LogException(excp, "Error en la función << RellenaDatosPerfil() >>");
            }

            using (Clases.cASPNET_INFO_USUARIO objUsuario = new Clases.cASPNET_INFO_USUARIO())
            {
                objUsuario.userid = this.iduser;
                if (objUsuario.bConsultar())
                {
                    txtFirstName.Text = objUsuario.nombre;
                    txtLastName.Text  = objUsuario.apellidos;
                    txtResume.Text    = objUsuario.resumen;
                    if ((!string.IsNullOrEmpty(objUsuario.apellidos)) && (!string.IsNullOrEmpty(objUsuario.nombre)))
                    {
                        lbNombreUsuario.Text = objUsuario.apellidos + ", " + objUsuario.nombre;
                    }
                    else if (!string.IsNullOrEmpty(objUsuario.apellidos))
                    {
                        lbNombreUsuario.Text = objUsuario.apellidos;
                    }
                    else if (!string.IsNullOrEmpty(objUsuario.nombre))
                    {
                        lbNombreUsuario.Text = objUsuario.nombre;
                    }
                    if (!string.IsNullOrEmpty(objUsuario.imageurl))
                    {
                        imagePerfilUsuario.ImageUrl = objUsuario.imageurl;
                    }
                    else
                    {
                        imagePerfilUsuario.ImageUrl = "~/images/noavatar.png";
                    }
                    if (string.IsNullOrEmpty(objUsuario.resumen))
                    {
                        lbResumenUsuario.Text = "You haven't provided a brief resume about you";
                    }
                    else
                    {
                        lbResumenUsuario.Text = objUsuario.resumen;
                    }
                }
                else
                {
                    Response.Redirect("~/errors/notfound.aspx");
                }
            }
        }
        else
        {
            Response.Redirect("~/errors/notfound.aspx");
        }
    }