S
Stephen Walch
I have a custom DataAdapter which derives from
System.Data.Common.DbDataAdapter and therefore inherits a property of type
System.Data.Common.DataTableMappingCollection. When I place an instance of
my adapter on a WinForm in VS.NET 2003, configure the SelectCommand (using
my custom data provider again) and try to edit the
DataTableMappingCollection, the
Microsoft.VSDesigner.Data.Design.DataTableMappingCollectionEditor complains
that it is "Unable to retrieve the schema from the database table. Source
column mapping information will not be available" and then fails with a
"Specified Cast is not valid" error.
So what is the DataTableMappingCollectionEditor expecting of my DataAdapter?
If it is trying to get schema information, it must be doing so through the
SelectCommand and it's corresponding Connection, but schema retrieval is not
a documented part of IDbCommand or IDbConnection. What is it the cast that
is failing here?
Thanks,
Steve
System.Data.Common.DbDataAdapter and therefore inherits a property of type
System.Data.Common.DataTableMappingCollection. When I place an instance of
my adapter on a WinForm in VS.NET 2003, configure the SelectCommand (using
my custom data provider again) and try to edit the
DataTableMappingCollection, the
Microsoft.VSDesigner.Data.Design.DataTableMappingCollectionEditor complains
that it is "Unable to retrieve the schema from the database table. Source
column mapping information will not be available" and then fails with a
"Specified Cast is not valid" error.
So what is the DataTableMappingCollectionEditor expecting of my DataAdapter?
If it is trying to get schema information, it must be doing so through the
SelectCommand and it's corresponding Connection, but schema retrieval is not
a documented part of IDbCommand or IDbConnection. What is it the cast that
is failing here?
Thanks,
Steve