Quantcast
Viewing all articles
Browse latest Browse all 2

Problem with Profiles in ASP .NET

I made an ASP .net application which use the asp .net login system. I use the a class which gets some details of the logged in user such as Name, address etc. In the page that the user can change his details i have those commands. If i don't use the commands in the page_load the address changes in the database successfully, but if i use them the database doesnt make the changes in the address. How is it possible? The profileC class uses the Inherits from ProfileBase class

       protected void Page_Load(object sender, EventArgs e)    {        if (HttpContext.Current.User.Identity.IsAuthenticated)        {            classes.ProfileC pr = classes.ProfileC.GetProfileC(HttpContext.Current.User.Identity.Name);            TxtAddress.Text = pr.UserAddress;        }    }    protected void BtnAdd_Click(object sender, EventArgs e)    {        classes.ProfileC pr = classes.ProfileC.GetProfileC(HttpContext.Current.User.Identity.Name);        pr.UserAddress = TxtAddress.Text;        pr.Save();    }}

Viewing all articles
Browse latest Browse all 2

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>