mandag 24. august 2009

More on Objectdatasource

First I needed to refresh. First hit got me here, with the answer. A simple call to GridView1.DataBind(); will cause the grid to refresh.

Then I need to handle exceptions. This is done by setting e.ExceptionHandled=true in a OnUpdated, OnDeleted etc func with the signature:
protected void OnUpdated(object sender, ObjectDataSourceStatusEventArgs e).

Then I needed to set whats the key to be passed into the DeleteMethod. This is done by setting the DataKeyNames on the grid

Ingen kommentarer:

Legg inn en kommentar