Can I stop Membership.GetUser() call from a particular page RRS feed

  • Question

  • User714249673 posted


    I am using password recovery control in my page. Although I stopped calling Membership.GetUser() from anywhere from my Page - ForgotPassword.aspx.cs. But at exit by default it is calling Membership.GetUser() and creating some issue. Can I completely stop calling Membership.GetUser() for a particular .aspx page?


    Supratik De

    Wednesday, April 22, 2020 4:29 PM


  • User753101303 posted


    Try to test User.Identity.IsAuthenticated so that you call GetUser() only if the user is authenticated. Does it work? If it still doesn't work knowiing which error you have could perhaps help.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, April 22, 2020 5:19 PM