What you want to see on DotNetFunda.com ?
DotNetFunda.Com Logo
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 4289 |  Welcome, Guest!   Register  Login
  Home > Community Home >

store logged in user id in database from class file

  Posted on: 2/29/2012 6:15:35 AM | Views: 8

Recommend an Articles | Recommended Articles | Search Resources | Community Home |




Hello all,
I am storing the user id for a record who creates it. It is working fine in aspx.cs file.
myReview.Owner = (Guid)Membership.GetUser().ProviderUserKey;
but when I use the same code in a class file in App_Code folder then it does not work and code breaks. 
Is there any other way to get user id in case of class file?
Please help me I am stuck on it for a long time.
Many thanks...
... Go to the complete details ...

Found interesting? Add this to:


About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/25/2013 11:15:40 PM