Re: Unable to cast object of type 'Oracle.DataAccess.Client.OracleComm
- From: "Brendan Reynolds" <brenreyn@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 19 Jan 2006 15:31:52 -0000
You'd probably be more likely to get responses to this question in an
ADO.NET forum. Try, for instance, microsoft.public.dotnet.framework.adonet
--
Brendan Reynolds
Access MVP
<eclypse@xxxxxxxxxx> wrote in message
news:1137681008.852250.5510@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> We're having the exact same problem, so any help would be greatly
> appreciated.
>
> Oz
>
> sam schreef:
>
>> Hi:
>>
>> I am not sure if this is the right place to post this question. Please
>> let
>> me know if it is not and I appreciate if someone could point me in the
>> right
>> direction.
>>
>> I am getting this error after converting to .NET 2.0.
>> Unable to cast object of type 'Oracle.DataAccess.Client.OracleCommand' to
>> type 'System.Data.Common.DbCommand'
>>
>> I am using, Oracle.DataAccess.Client and not Microsoft .NET framework
>> provided System.Data.OracleClient.
>>
>> This is the error trace:
>> [InvalidCastException: Unable to cast object of type
>> 'Oracle.DataAccess.Client.OracleCommand' to type
>> 'System.Data.Common.DbCommand'.]
>> System.Data.Common.DbDataAdapter.get_SelectCommand() +34
>> System.Data.Common.DbDataAdapter.FillSchema(DataTable dataTable,
>> SchemaType schemaType) +54
>>
>> The line in my code where the exception occurs is:
>> CType(DA, OracleDataAdapter)
>> where DA is of type: IDbDataAdapter
>>
>> This code used to work fine with .NET 1.1. After some initial research I
>> found that "System.Data.Common.DbCommand " is new in .NET 2.0.
>>
>> Any help would be greatly appreciated.
>>
>> Thanks,
>> Sam
>
.
- References:
- Prev by Date: Re: Unable to cast object of type 'Oracle.DataAccess.Client.OracleComm
- Next by Date: Permissions to allow creation of forms etc?
- Previous by thread: Re: Unable to cast object of type 'Oracle.DataAccess.Client.OracleComm
- Next by thread: Permissions to allow creation of forms etc?
- Index(es):