Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3545
  • Last Modified:

ASP.NET 2.0 web app referencing adodb and adodb.net

I need help unreferencing a reference in an ASP.NET 2.0 web project.

I have a web project that had a reference to ado.  Someone added a reference to ado.net to the project and we got the compilation error:

The type 'ADODB.Connection' exists in both 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\webapp\8a30a549\4af9b613\assembly\dl3\04275478\0007ea7b_d409c701\Interop.ADODB.DLL' and 'c:\WINDOWS\assembly\GAC\ADODB\7.0.3300.0__b03f5f7f11d50a3a\adodb.dll'

This is to be expected since both have an ADODB.Connection object.

Now my problem is that i cannot unreference ado.net.  I thought i could do this in the web.config file but all my references are being readded there when i recompile.  Here is a snippet from my web.config.

<compilation defaultLanguage="c#" debug="true" strict="true">
      <assemblies>
            <add assembly="System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
            <add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
            <add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
            <add assembly="System.DirectoryServices, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="Microsoft.VisualBasic, Version=8.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="Microsoft.VisualBasic.Compatibility, Version=8.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="Microsoft.Interop.Security.AzRoles, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
            <add assembly="mscomctl, Version=10.0.4504.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="MSDATASRC, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="Microsoft.Office.Interop.Owc11, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71E9BCE111E9429C"/>
            <add assembly="stdole, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
            <add assembly="ADODB, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
      </assemblies>
</compilation>

I dont know which one is ado.net but i'm guessing that
<add assembly="ADODB, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
represents old ado.  When i delete that one, the line is always re-added when recompile.

I my question is: How to i unreference ado.net so my code works again (it won't even compile now)?
0
dave4dl
Asked:
dave4dl
  • 2
1 Solution
 
dave4dlAuthor Commented:
You right click on the web project and select "property pages".  You then see a list of reference and have the option to add or remove them.
0
 
Sashi RachabattulaSCRUM Master, .NET Project LeadCommented:
Detele all files at \Temporary ASP.NET Files\
0
 
dave4dlAuthor Commented:
Thanks for posting rsashi.

I have tried doing that (deleting those folders) but the reference still came back).

The solution i posted works.
0
 
DarthModCommented:
PAQd, 500 points refunded.

DarthMod
CS Moderator
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now