0

I am getting this error when I am using ODP.net The error is appearing when I include a connection

<Connection AppSettingsObjectName="Web.config" AppSettingsPropertyName="BannerCS" ConnectionStringObject="" IsAppSettingsProperty="true" Modifier="Assembly" Name="BannerCS (Web.config)" ParameterPrefix=":" PropertyReference="AppConfig.System.Configuration.ConfigurationManager.0.ConnectionStrings.BannerCS.ConnectionString" Provider="Oracle.ManagedDataAccess.Client" />

in the .XSD file in the website project I have the following connection in the web.config file

    <add name="BannerCS" connectionString="DATA SOURCE=******;PASSWORD=**********;PERSIST SECURITY INFO=True;USER ID=*********"
  providerName="Oracle.ManagedDataAccess.Client" />

I am able to see the data by running the SQL query in the data table in the Data set. The website project that is based on .net 3.5 also does not give any error in compile time . But when I run the application it gives this error.

Also when I add reference to the

Oracle.ManagedDataAccess.dll

by adding this in the web.config

<add assembly="Oracle.ManagedDataAccess, Version=4.121.1.0, Culture=neutral, PublicKeyToken=89B483F429C47342"/>

it give this error

Configuration Error 
  Description: An error occurred during the processing of a configuration file required to     service this request. Please review the specific error details below and modify your configuration file appropriately. 

 Parser Error Message: Could not load file or assembly 'Oracle.ManagedDataAccess, Version=4.121.1.0, Culture=neutral, PublicKeyToken=89b483f429c47342' or one of its dependencies. The system cannot find the file specified.
Ortomala Lokni
  • 56,620
  • 24
  • 188
  • 240
Shomaail
  • 493
  • 9
  • 30
  • Hi Shomaail, My trouble I'm facing seems to be same. I can only see this letter 'Parser Error Message' on my screen, but except for that, I don't have any clues. Could you tell me where I can get that log like you desscribed?? – saya24 Oct 16 '19 at 01:59
  • Just use .net 4.0 or later the error will go away inshAllah – Shomaail Oct 17 '19 at 08:51
  • Thank you for the comment. My problem was comletely defferent from yours. That dll wasn't in the machine.config of that web server. I seemed to mistake the order to set up that web server, should had acttivate .NETFramework prior to instaling ODAC. So I wrote it manualy, then could get over this. Huu... – saya24 Oct 21 '19 at 12:44

1 Answers1

0

This error comes at .net version 3.5 The solution is to upgrade the .net version to .net 4.0 or above

Shomaail
  • 493
  • 9
  • 30