[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 682
  • Last Modified:

The type or namespace ProfileCommon could not be found error

Hello all,

I am seeing this
"The type or namespace ProfileCommon could not be found error" even though

1. I have used using System.Web.Profile;
2. I have <profile enabled = "true">

I am not sure why I am seeing this error
0
TheCommunicator
Asked:
TheCommunicator
  • 4
  • 4
4 Solutions
 
Carlos VillegasFull Stack .NET DeveloperCommented:
ProfileCommon do not exist, you need to create that class (), follow this instructions:
http://www.infinitezest.com/articles/saving-the-custom-user-data-from-createuserwizard-via-profiles.aspx
0
 
Carlos VillegasFull Stack .NET DeveloperCommented:
ProfileCommon do not exist, you will need to create that class, follow this instructions to create it:
http://www.infinitezest.com/articles/saving-the-custom-user-data-from-createuserwizard-via-profiles.aspx
0
 
TheCommunicatorAuthor Commented:
Well that give me following error:

Unable to cast object of type 'System.Web.Profile.DefaultProfile' to type 'ProfileCommon'.

when I try to create a new blank profile.....
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Carlos VillegasFull Stack .NET DeveloperCommented:
Can you do this:
Inherit your ProfileCommon class from System.Web.Profile.DefaultProfile
Instead of System.Web.Profile.ProfileBase
Example:
public class ProfileCommon : System.Web.Profile.DefaultProfile

Open in new window

0
 
TheCommunicatorAuthor Commented:
That did not work either. Sam error.......
0
 
Carlos VillegasFull Stack .NET DeveloperCommented:
Can you check how many ProfileCommon class have your project? do a search, maybe it exists in other place...
0
 
TheCommunicatorAuthor Commented:
I checked and there in only one ProfileCommin definition....
0
 
TheCommunicatorAuthor Commented:
Well, I found the reason.  It is because I have defined Profile in Web.config and my project is a web application which does not compile web application. So I have to do something like

ProfileCommon:ProfileBase

Thanks
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now