Writing a routine WinForms app that references a few custom libraries written by myself. I am building one particular library which depends on another library and, when I do, I get the following warning message:
"Could not load file or assembly 'RHLib' Version 1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified"
The application functions, there are no error messages, but I am one of those that likes a completely clean compile - no errors, no warnings. And I cannot figure this one out.
The library in question has a reference to the "missing" library, the "missing" library is compiled and lives in the Debug directory when VS finishes compiling, the build order places the "missing" library as the first item built and the "missing" library has no dependencies - its a small library built to get me out of a circular assembly problem.
Any ideas?
C programming language is a machine-independent programming language that is mainly used to create many types of applications and operating systems such as Windows, and other complicated programs such as the Oracle database, Git, Python interpreter, and games and is considered a programming foundation in the process of ...
What is C? C is a general-purpose programming language created by Dennis Ritchie at the Bell Laboratories in 1972. It is a very popular language, despite being old. C is strongly associated with UNIX, as it was developed to write the UNIX operating system.
Compared to other languages—like Java, PHP, or C#—C is a relatively simple language to learn for anyone just starting to learn computer programming because of its limited number of keywords.
In the real sense it has no meaning or full form. It was developed by Dennis Ritchie and Ken Thompson at AT&T bell Lab. First, they used to call it as B language then later they made some improvement into it and renamed it as C and its superscript as C++ which was invented by Dr.
Even though the warning was coming from the library that used the "missing" library, adding a reference to the application which called the library which called the "missing" library removed the warning.
Explanation: The original assembly (we'll call it AS0) called another assembly (we'll call this one AS1). AS1 was in the reference list of AS0, however, AS1 called still another assembly (we'll call it AS2) and, of course, AS2 is in the reference list of AS1 but NOT in the reference list of AS0. To solve the problem, I added AS2 to the reference list of AS0. That did the trick.
Did you right click on the project, and click Add Reference, and then add using RHLib; to the top of the file?
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