Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. ODP.Net provider error

ODP.Net provider error

Scheduled Pinned Locked Moved ASP.NET
csharpasp-netdatabaseoraclevisual-studio
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    vanikanc
    wrote on last edited by
    #1

    Hello, I downloaded and installed the ODAC for 64 bit machine. There were no issues installing, except that you have a to execute a sql file at the end of installation. It is located at c:\app\\product\11.2.0\client\Asp.net\SQL - Where would I execute this? From DOS prompt? I added the Oracle.DataAccess.dll to VS 2010. I keep getting this error - Error 2 Could not load file or assembly 'Oracle.DataAccess, Version=4.112.3.0, Culture=neutral, PublicKeyToken=89b483f429c47342' or one of its dependencies. The system cannot find the file specified. C:\projects\CSCC-DotNet\Web.config 14 any ideas? I did search the web, but with no luck. Thanks!

    J 1 Reply Last reply
    0
    • V vanikanc

      Hello, I downloaded and installed the ODAC for 64 bit machine. There were no issues installing, except that you have a to execute a sql file at the end of installation. It is located at c:\app\\product\11.2.0\client\Asp.net\SQL - Where would I execute this? From DOS prompt? I added the Oracle.DataAccess.dll to VS 2010. I keep getting this error - Error 2 Could not load file or assembly 'Oracle.DataAccess, Version=4.112.3.0, Culture=neutral, PublicKeyToken=89b483f429c47342' or one of its dependencies. The system cannot find the file specified. C:\projects\CSCC-DotNet\Web.config 14 any ideas? I did search the web, but with no luck. Thanks!

      J Offline
      J Offline
      Jasmine2501
      wrote on last edited by
      #2

      It is telling you it can't find the DLL. On line 14 in your web.config, you're referencing a DLL, and for some reason the runtime system can't find it. Either the assembly is not in the GAC, or the path you specified is wrong. In my Web.config the tag looks like this:

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

      Which suggests the assembly is found in the GAC - which is where the installer should have placed it. This has nothing to do with the SQL scripts, which have probably already been run on your server - they only need to be run once for each server, so if you're the second or later developer to install this, you can skip it. One way to "reset" VS in terms of finding this assembly is to go into your project property pages, open the "references" and remove the Oracle.DataAccess reference. Then save your project, I usually restart VS, then right-click the bin, choose "Add Reference..." and add the Oracle DLL back in. That should help it find the thing correctly. If that doesn't work, drop a copy of the Oracle.DataAccess.DLL into the bin.

      V 1 Reply Last reply
      0
      • J Jasmine2501

        It is telling you it can't find the DLL. On line 14 in your web.config, you're referencing a DLL, and for some reason the runtime system can't find it. Either the assembly is not in the GAC, or the path you specified is wrong. In my Web.config the tag looks like this:

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

        Which suggests the assembly is found in the GAC - which is where the installer should have placed it. This has nothing to do with the SQL scripts, which have probably already been run on your server - they only need to be run once for each server, so if you're the second or later developer to install this, you can skip it. One way to "reset" VS in terms of finding this assembly is to go into your project property pages, open the "references" and remove the Oracle.DataAccess reference. Then save your project, I usually restart VS, then right-click the bin, choose "Add Reference..." and add the Oracle DLL back in. That should help it find the thing correctly. If that doesn't work, drop a copy of the Oracle.DataAccess.DLL into the bin.

        V Offline
        V Offline
        vanikanc
        wrote on last edited by
        #3

        When I installed the ODAC componenets for .Net, there was a folder created, in addition to adding the dll to GAC, C:\app\\product\11.2.0\client_1\odp.net\bin\4\ORacle.DataAccess.dll. I am using this reference in my web site. Maybe this is the problem. How can I un-reference this one and add this one - C:\Windows\Microsoft.NET\assembly\GAC_64\Oracle.DataAccess\v4.0_4.112.3.0__89b483f429c47342\ORacle.DataAccess.dll?? In m web.config file, there is the same listing

        Thanks so much for your help!!

        J 1 Reply Last reply
        0
        • V vanikanc

          When I installed the ODAC componenets for .Net, there was a folder created, in addition to adding the dll to GAC, C:\app\\product\11.2.0\client_1\odp.net\bin\4\ORacle.DataAccess.dll. I am using this reference in my web site. Maybe this is the problem. How can I un-reference this one and add this one - C:\Windows\Microsoft.NET\assembly\GAC_64\Oracle.DataAccess\v4.0_4.112.3.0__89b483f429c47342\ORacle.DataAccess.dll?? In m web.config file, there is the same listing

          Thanks so much for your help!!

          J Offline
          J Offline
          Jasmine2501
          wrote on last edited by
          #4

          I think you can do the swap with the references window in your project properties. I just checked my site, and I'm using the "DLL in the bin folder" method. I don't remember why, but I think it's because the locations are different in the server.

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups