I am building C# Console Application to connect with database and do simple query.
But when I debug program, I get this error:
The type or namespace name 'Oracle' could not be found ( are you missing a using directive or an assembly reference? )
I need to use:
using Oracle.DataAccess.Client;
I have downloaded from Oracle site ODAC pack. Inside I have Install batch file ( i have used it ) but nothing still.
I am using MS VS2012 Express for Windows Desktop.
What file should I include when adding a reference ?
Agreed you need to reference :
Oracle.DataAccess.dll
You may need to be careful that you have the right Oracle client installed - if you have the 32bit one then you may need to force your app into 32 bit mode.
For distribution you may also want to include all the dependencies in your BIN folder - for 32bit that would look like :
In the install location of the pack you downloaded there is
Oracle.DataAccess.dll
which you should reference. Here is a guide doing exactly that.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With