Save ??

Posts   
 
    
wmswartz
User
Posts: 4
Joined: 15-Jul-2013
# Posted on: 15-Jul-2013 04:57:56   

Downloaded the trial pro version. Can't seem to figure out where the Save() method is.

Using SelfServicing Compiled using General (1 class)

Followed example for creating a new entity instance.

Added the Entity Class Instantiated the Entity Class Added Properties Wanted to add .Save() method, but it does not exist (either in intellisense or compiling).

Any thoughts??

Thanks Bill

daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 15-Jul-2013 07:33:22   

Hi Bill,

The .Save method is in the entity you create. There is an example in the documentation.

Also, it's important to make sure that you are referencing the correct LLBLGen Runtime assemblies (required for compile your code). Please read the documentation section Compiling your code.

David Elizondo | LLBLGen Support Team
wmswartz
User
Posts: 4
Joined: 15-Jul-2013
# Posted on: 15-Jul-2013 17:45:47   

Yes, I understand that the Save() method "should" be in the entity that you create.

I'm sure this sounded like a NOOB question, but been working with ORM's & Generators for a while and thought I would try LLBL. Comfortable with CodeSmith and Sonic.

So the Solution includes the LLBLGen code It includes all the EntityClasses that I created

It also includes a number of action Methods. - FetchUsingPK - GetSingleCategory - CreateDAOInstance

What it doesn't have is the "Save()" method.

EquipmentEntity equip = new EquipmentEntity(); equip.Description = "Dummy Desc"; equip.Save(); //This fails at compile because Save does not exist.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39912
Joined: 17-Aug-2003
# Posted on: 15-Jul-2013 18:06:37   

Please see: http://www.llblgen.com/tinyforum/Messages.aspx?ThreadID=10945

You likely generated code for adapter, (you have two generated code projects?). Adapter doesn't have .Save() on the entity, selfservicing does. Adapter is a different paradigm, we support two: SelfServicing and adapter. Please see: http://www.llblgen.com/documentation/4.0/LLBLGen%20Pro%20RTF/hh_goto.htm#Concepts/concepts_templatesets.htm for more information about the differences between the two.

Frans Bouma | Lead developer LLBLGen Pro
daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 15-Jul-2013 18:07:46   

As I said, I think you are missing the runtime libraries dll references.

daelmo wrote:

Also, it's important to make sure that you are referencing the correct LLBLGen Runtime assemblies (required for compile your code). Please read the documentation section Compiling your code.

David Elizondo | LLBLGen Support Team
wmswartz
User
Posts: 4
Joined: 15-Jul-2013
# Posted on: 17-Jul-2013 00:39:00   

@Otis Tried all 4 Adapter, General and 2 classes SelfService and General/2 classes

@daelmo Check the references in the LLBL project and they libraries are there. DQE.SQLServer & ORMSupportClasses

Are there any other libraries needed? Should they be in some other location?

daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 17-Jul-2013 07:40:13   

wmswartz wrote:

@daelmo Check the references in the LLBL project and they libraries are there. DQE.SQLServer & ORMSupportClasses

Are there any other libraries needed? Should they be in some other location?

Make sure that ORMSupportClasses is referenced in your GUI (WinForm, Console, WebApp, etc) and every project that uses (i.e. reference) your LLBLGen generated project.

Also, as you tried all Adapter template sets and selfServicing, maybe you are using the generic adapter llblgen generated project, instead of the selfServicing one. If you are not sure, try to generate into a new empty folder, open it, add your GUI, check references, etc, and compile.

David Elizondo | LLBLGen Support Team