I've added a class library project to my application.
In one of my classes, I need to use the MembershipUser class, but the project can't find it. I've added references to System.Web, System.Web.Security, and System.Security.Principal.
I'm not sure what the problem is. Has anyone run into this?
If you are using .NET 4.0 you need to reference the System.Web.ApplicationServices.dll
assembly. As always the documentation of the MembershipUser contains all the necessary information:
Namespace: System.Web.Security
Assembly: System.Web.ApplicationServices (in System.Web.ApplicationServices.dll)
In previous versions of the framework the MembershipUser class was located in the System.Web.dll
assembly.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With