Datasource does not work with Telerik radgrid

Posts   
 
    
Posts: 1263
Joined: 10-Mar-2006
# Posted on: 06-Jul-2006 07:18:59   

I drop a LLBLGenProDataSource on a webform and attach it to a Telerik radgrid.

The data will display, but add/update/delete operations do not work. No error or anything, just dont work.

I drop a Microsoft GridView on the same webform, attach it to the same DataSource and it will work fine.

The Telerik RadGrid works with a normal ObjectDataSource or whatever...

Using VS2005, ASP 2.0 and your July 1 release of LLBLGen.

Any help please?

pandu avatar
pandu
User
Posts: 86
Joined: 18-May-2006
# Posted on: 06-Jul-2006 07:45:33   

WayneBrantley wrote:

I drop a LLBLGenProDataSource on a webform and attach it to a Telerik radgrid.

The data will display, but add/update/delete operations do not work. No error or anything, just dont work.

I drop a Microsoft GridView on the same webform, attach it to the same DataSource and it will work fine.

The Telerik RadGrid works with a normal ObjectDataSource or whatever...

Using VS2005, ASP 2.0 and your July 1 release of LLBLGen.

Any help please?

I am also testing with Telerik RadGrid and it loads the data and allow me to edit/update etc.

Could you post some code?

Posts: 1263
Joined: 10-Mar-2006
# Posted on: 06-Jul-2006 07:49:56   

Well, I did not write any code!

I just dragged and dropped in webform and hooked everything up visually with a 'clickty-click'. I connected my LLBLGenProDataSource to an EntityCollection.

I am using Self Servicing.

What are you using and do you have any code on your form?

Walaa avatar
Walaa
Support Team
Posts: 14981
Joined: 21-Aug-2005
# Posted on: 06-Jul-2006 07:54:36   

Strange coz anything that works with ObjectDataSource should work with LLBLGenProDataSource.

Maybe you should ask them, or see how Pandu got it working.

pandu avatar
pandu
User
Posts: 86
Joined: 18-May-2006
# Posted on: 06-Jul-2006 08:01:50   

WayneBrantley wrote:

Well, I did not write any code!

I just dragged and dropped in webform and hooked everything up visually with a 'clickty-click'. I connected my LLBLGenProDataSource to an EntityCollection.

I am using Self Servicing.

What are you using and do you have any code on your form?

Ok.. I use Adapter and it's Datasource control. It works fine. With LivePersistance = false, I have code in PerformSelect and PerformWork.

Anyway, post your HTML Source code.

pandu avatar
pandu
User
Posts: 86
Joined: 18-May-2006
# Posted on: 06-Jul-2006 08:26:06   

Did you set AllowAutomaticInserts and AllowAutomaticUpdates to True in the RadGrid?

Posts: 1263
Joined: 10-Mar-2006
# Posted on: 06-Jul-2006 17:37:40   

Well, it took 20 minutes, but I figured it out.

I had taken a grid that was using ObjectDataSource and replaced it with the LLBLGenProDataSource. When I started with a brand new grid and hooked everything up, it worked.

The problem is, it had the DataKeyNames field set to 'FieldNameID' from the objectdatasource....as you know, LLBLGen names that field 'FieldNameId'.

Once I spotted that and corrected the case, it worked!!

(Note, before I posted this, I did start with a new RadGrid - but I also forgot to turn on the automatic updating.....whoops....)

Thanks Pandu!