Print Page | Close Window

IIdGenerator implementation

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce 2010
Forum Discription: For .NET 4.0
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=3300
Printed Date: 25-Mar-2025 at 12:31pm


Topic: IIdGenerator implementation
Posted By: Sakar SR
Subject: IIdGenerator implementation
Date Posted: 25-Feb-2012 at 1:38pm
while IIdGenerator implementation the following error is thrown.

Code:

 public static SysUser Create(EntityManager pManager)
        {
            SysUser aSysUser = new SysUser();

            // if this object type requires a unique id and you have implemented
            // the IIdGenerator interface implement the following line

            pManager.GenerateId(aSysUser, SysUser.PropertyMetadata.RecID);

            // Add custom code here

            aSysUser.EntityAspect.AddToManager();
            return aSysUser;
        }

Error:

Object referance not set to an instance of an object

My data base has an tabel for NextId, with on record for GLOBAL

and i place the IIdGenerator class in my BOL.





Replies:
Posted By: sbelini
Date Posted: 27-Feb-2012 at 1:51pm
Hi Sakar,
 
Can you provide the code for your IidGenerator?
 
Silvio.


Posted By: Sakar SR
Date Posted: 28-Feb-2012 at 7:53am
Hi sbelini,

thank you for your concern. the problem was not on Iidgenerator. i fixed it .
it was on the other function i called in my program.

Learning  Ideablade is Interesting . Ya! it is a great technology you guys have build.

After learning little more i made up my mind to buy this wonderful product.

Have a nice day.






Print Page | Close Window