does not contain a definition for 'EntityType'

Posts   
 
    
nevernet
User
Posts: 67
Joined: 01-Feb-2010
# Posted on: 12-Apr-2010 08:39:22   

Error 86 'xxx.EntityClasses.xxxEntity' does not contain a definition for 'EntityType' and no extension method 'EntityType' accepting a first argument of type 'xxx.EntityClasses.xxxEntity' could be found (are you missing a using directive or an assembly reference?)

LLBLGen 2.5

SD.LLBLGen.Pro.ORMSupportClasses.NET20.dll (2.5.8.214)

is there something wrong with my project?

Thank you Daniel.

Walaa avatar
Walaa
Support Team
Posts: 14994
Joined: 21-Aug-2005
# Posted on: 12-Apr-2010 09:06:41   

The EntityType enum is suposed to be under your application root namespace.

Would you please post the line of code which gives this compilation error?

nevernet
User
Posts: 67
Joined: 01-Feb-2010
# Posted on: 12-Apr-2010 09:09:53   

1.

/// <summary>Creates entity fields object for this entity. Used in constructor to setup this entity in a polymorphic scenario.</summary>
        protected virtual IEntityFields CreateFields()
        {
            return EntityFieldsFactory.CreateEntityFieldsObject(TmGetStartedForm.EntityType.TmGetStartedFormPaymentEntity);
        }

2.


/// <summary>Returns the TmGetStartedForm.EntityType enum value for this entity.</summary>
        [Browsable(false), XmlIgnore]
        public override int LLBLGenProEntityTypeValue 
        { 
            get { return (int)TmGetStartedForm.EntityType.TmGetStartedFormPaymentEntity; }
        }

actually ,there are many errors in this case. thank you in advance.

nevernet
User
Posts: 67
Joined: 01-Feb-2010
# Posted on: 12-Apr-2010 09:14:42   

hm..

i think i understand what's the problem. the name of root namespaces is same as my one class name