Entity to custom DTO class

Posts   
 
    
Posts: 7
Joined: 07-Mar-2008
# Posted on: 26-Mar-2008 11:16:56   

Hi.. Can anyone help me out with this.. I am using Adapter templates and LLBLGenPro v2.5

I have the following table structure

Table1 Table1ID int PK Table1Name varchar(50) Table1Description varchar(250)

and i have a custom DTO class

class Table1DTO {

int _id; string _name; string _description;

}

I want to create an object of Table1Entity (generated by LLBLGen) by passing it an ID, and map its contents to an object of my Table1DTO class

Thanks in advance

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 26-Mar-2008 11:26:08   

Please check .NET 2.0: projection to custom classes in the LLBLGen Pro manual's section "Using the generated code -> SelfServicing/Adapter -> Using the EntityView class"

Posts: 7
Joined: 07-Mar-2008
# Posted on: 26-Mar-2008 14:03:48   

Thanks.. and apologies for not checking the documentation first.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 26-Mar-2008 14:14:02   

no problem. simple_smile