EntityBase.Save() not an object?

Posts   
 
    
benles
User
Posts: 62
Joined: 02-May-2005
# Posted on: 03-May-2005 00:44:12   

I'm new to llblgen and am trying a simple ASP.NET datagrid editing page. When inserting a new record, I call the following code.

private void btnCreate_Click(object sender, System.EventArgs e) { ResourceEntity r = new ResourceEntity(); r.Name=this.txtName.Text; r.Description=txtDescription.Text; r.Url=txtUrl.Text; r.Save(); }

On r.Save(), I get the error:

[NullReferenceException: Object reference not set to an instance of an object.] SD.LLBLGen.Pro.ORMSupportClasses.EntityBase.Save() +30

Can anyone assist?

Thanks,

Ben

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39933
Joined: 17-Aug-2003
# Posted on: 03-May-2005 10:18:16   

Be sure you have the appSettings section in your web.config file, copied from the generated app.config file.

Frans Bouma | Lead developer LLBLGen Pro