|
-
August 3rd, 2010, 05:54 PM
#4
Re: Integrating MatLab with C#
The assembly references added to the project are design/compile-time references, that enable you to write the code; at runtime however, a different assembly location resolution process occurs. You can look at these articles to learn more: Resolving Names to Locations (1) [scroll down a bit to see a flowchart if you want to avoid the details], How the Runtime Locates Assemblies (2).
This normally isn't a problem and it enables a .NET app to run on any specific system (provided that the .NET framework is installed and that the required assemblies exist there).
Since you've said that the referenced assembly is the local copy, I'm guessing that the runtime checks some other locations first and finds a different version.
This can turn out to be tricky.
If you read through the articles (1) and (2), you'll see that there could be a *.config file in your project folder (or subfolder), containing some codeBase entries telling the runtime where to look. Check for these, maybe you'll find an entry with the path to the assembly that gets loaded. There's a nice short example of such .config file entries in article (1), so you can see there what it is you're looking for.
It can also help if you copy the assembly dll to the project folder, so if you havent done that, try it.
Also, you might want to try to rebuild the whole solution ("Build" menu --> "Rebuild Solution"), but I'm not sure this will help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|