You thought with .NET 2.0 that all your data binding woes had been answered. Oh how very wrong you were, you poor, poor developer (emphasis on poor; these are hard times, what with house prices soaring and whatnot).
It is true to say that you can use an ObjectDataSource in conjunction with a GridView control to present data to the user in a nice tabular format, though you are not likely to achieve this without a) pain b) coffee and c) (in extreme cases) a near-death experience.
Here are some brief and scattered notes on my experiences whilst attempting to use Object Data Sources:
- Update methods can get easily out of synch. There is a hack-around/fix for this - use the ODS 'OnUpdating' method, like so:
//protected void DtypesODS_Updating(object source, ObjectDataSourceMethodEventArgs e)And obviously add a ref to that in your aspx, or initialise the event by overriding OnInit.
{
// Modify input parameters because ODS is too dumb to figure it out.
if (e.InputParameters.Contains("DType"))
e.InputParameters.Remove("DType");
}
[More to come.]
1 comment:
I found this in your profile
It is the gayest thing I've ever seen
I think I just burst with geeklove <3
Post a Comment