none
ASP.NET Cannot re-add a DLL reference to project RRS feed

  • Question

  • Hello,

    I have a ASP.NET web project in visual studio 2015 using asp framework 4.0 and .NET 4.6 and have a problem with my project unable to see references to other C# DLLs created in other projects.  When I compile the website project, it emits the error "error CS0246: The type or namespace name 'NetworkManagerState' could not be found (are you missing a using directive or an assembly reference?)".  I'm trying to re-reference the NetworkManagerState.dll file but it is failing.  There are other references to other DLLs that are also missing.

    I recently upgraded all our projects from using .NET 3.5, x86 to .NET 4.6 and x64.  When I imported the existing web site project again into the solution, the references to DLLs in the BIN directory would not appear in the References properties page for the website project.  I try to add the reference again, but it doesn't work.

    I have several questions:

    Is there currently a bug in visual studio that causes this problem?

    Where in the solution file or other file is the reference to the paths to the DLLs being imported (so I can manually edit)?

    How can I re-add these references so they appear in the project without completely recreating the project (there are 50+ ASP forms pages and many ancillary CSS, Image, etc files).

    I appreciate any and all information on this problem.

    Thanks and best regards,

    Steve

    • Moved by CoolDadTx Friday, November 10, 2017 3:09 PM ASP.NET related
    Wednesday, November 8, 2017 7:43 PM

All replies

  • I recently upgraded all our projects from using .NET 3.5, x86 to .NET 4.6 and x64.  When I imported the existing web site project again into the solution, the references to DLLs in the BIN directory would not appear in the References properties page for the website project.  I try to add the reference again, but it doesn't work.

    You went from a 32 bit solution to a 64 bit solution? Why,  because if it's not broke then why fix it? Now it's broke.

    You should have just left it at 32 bit and configured IIS on the 64 bit machine to run a 32 bit solution. 

    https://www.codeproject.com/Tips/325824/Running-a-bit-application-under-IIS-on-a-bit

    Any new solutions, you can go to 64 bit.

    You could try the IIS forum for advise.

    https://forums.iis.net/

    Wednesday, November 8, 2017 8:08 PM
  • All of the DLLs in our project went to 64 bit.  The web project uses some of these DLLs, so that is why it went to 64 bit.  So there is no way to go back to 32 bit at this point.

    Anyway, it seems the project will still be broken when I try to go back to 32 bit anyway.  So I still need a way to fix it.

    Thanks...steve--

    Wednesday, November 8, 2017 8:36 PM
  • I left out the ASP.NET forums.

    http://forums.asp.net/

    Wednesday, November 8, 2017 8:49 PM
  • You say "but it is failing" and "doesn't work". Those are phrases that nearly always need clarification.

    As for manually editing things that you can't edit in a designer, that is the type of thing that can mess things up and can be impossible for you to get help fixing if you don't describe in details what you did. If you have already done something like that then it is likely impossible to help you. The solution might be to undo something you have already done.



    Sam Hobbs
    SimpleSamples.Info

    Thursday, November 9, 2017 8:40 PM
  • I try to explain my problem as best as I can.  I always leave things out because I try to draft a question without being too confusing.  Sometimes typing a huge, drawn-out scenario will get too long and confusing.  If you need more information to help with finding a solution, I will happily provide it.

    When I say "fail", I mean, when I try to add references to managed DLLs they fail to show up in the References property page of the project.  There is no error message and the reference actually does appear in BIN, but my intellisense is complaining about the references to these DLLs and my project won't compile.

    I did not manually change anything in my project.  I just offered that as a solution if at all possible.  I certainly am not averse to a little hand jamming if it gets the job done.

    Thx...steve--

    Friday, November 10, 2017 1:54 PM
  • Please post questions related to ASP.NET and web development in the ASP.NET forums. They can better assist you with this problem.

    Michael Taylor http://www.michaeltaylorp3.net

    Friday, November 10, 2017 3:09 PM

  • If there is currently a bug you can find it at, 

    http://connect.microsoft.com

    not in a forum, here are no Microsoft persons who have any information about that. 

    What I find strange that you tell you compile while there is an error.


    Success
    Cor


    Friday, November 10, 2017 3:15 PM