Connection property has not been initialized error

Connection property has not been initialized error

Postby scott.pedersen » Thu 08 Jun 2006 09:39

Hi,

I am getting the error 'Connection property has not been initialized' when I create and try an execute an OracleCommand object.

I have created the OracleConnection and tested it and it connects to Oracle. What am I missing that is causing this error to occur?

Cheers,

Scott.
scott.pedersen
 
Posts: 21
Joined: Tue 06 Jun 2006 03:14
Location: Auckland, New Zealand

Postby Alexey » Thu 08 Jun 2006 11:01

Set
Code: Select all
oracleCommand1.Connection=oracleConnection1
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby scott.pedersen » Thu 08 Jun 2006 19:44

Hi Alexey,

Shouldn't there be an automatic relationship between the connection and the command object?

Why does this need to be set manually?

Cheers,

Scott.
scott.pedersen
 
Posts: 21
Joined: Tue 06 Jun 2006 03:14
Location: Auckland, New Zealand

Postby Alexey » Fri 09 Jun 2006 06:14

There should be no automatic relationship between the connection and the command object, because any form may have more than one OracleConnection component.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43


Return to dotConnect for Oracle