Options

How to resolve the error while using the generated dll fro

kasikasi Posts: 2
edited October 7, 2016 6:40PM in SmartAssembly
Hi Support,

I have downloaded smartassembly trial version and use the geneareted dll with my application.I am facing the below error in my application when using embed assembly and try to refer it.

"Could not load file or assembly 'mylib' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)"

I just tried to generate the single assembly using smart assembly tool. I have added that assembly in reference folder and refer that in web.config file in my application

Herewith I have attached saproj file, assembly file which is generated from smart assembly tool.

Could you please provide any solution on this?

Attachment Link:Download here

Regards,
Kasithangam

Comments

  • Options
    Jessica RJessica R Posts: 1,319 Rose Gold 4
    Hi and thanks for your post!

    From what you've described, it sounds like SmartAssembly may have embedded the wrong version of your dependency so that it's failing to load at runtime.

    To make sure that SmartAssembly uses the correct version, can you please try adding a MandatoryPath attribute for the dependency into your saproj file to point it to the correct version?

    <Assembly AssemblyName="SmartPropertyGrid" MandatoryPath="c:path oyourfile.dll">

    (For more on how SmartAssembly locates dependencies and using the MandatoryPath attribute, kindly take a look here: https://documentation.red-gate.com/disp ... pendencies)

    I hope that helps but please let us know if not!

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


Sign In or Register to comment.