0

I'm working on my .net web application that need to execute some methods from unmanaged library. I used amazon web services for deploy. I found the path, where my application placed after deploy:

C:\inetpub\wwwroot\

It has bin folder with my unmanaged dll:

C:\inetpub\wwwroot\bin\Assimp32.dll

To allow my application use unmanaged dll's, I added this folder to environmental variable PATH. Here is my PATH variable:

"C:\inetpub\wwwroot\bin"

I set this variable every time in my "global.asax.cs":

  protected void Application_Start(object sender, EventArgs e)
        {
            System.Environment.SetEnvironmentVariable("PATH", Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "bin"));
        }

But I got not found error: "The specified module could not be found. (Exception from HRESULT: 0x8007007E)"

I made all steps, described here

Any ideas to fix it? :(

Community
  • 1
  • 1
Artem Kulikov
  • 2,250
  • 19
  • 32
  • How are you calling the code in the library? You need to include an [MCVE](http://stackoverflow.com/help/mcve) in your question. – mason May 12 '17 at 15:43
  • I have c# wrapper, provided by other developer. – Artem Kulikov May 12 '17 at 16:14
  • You probably need to move C:\inetpub\wwwroot\bin\Assimp32.dll to C:\inetpub\wwwroot\YourWebSiteDirectory\bin\Assimp32.dll . You might be able to solve your problem by moving the \bin directory to your websites root directory. – ThomW May 12 '17 at 19:38
  • Not sure. Because in this folder I have all my site. So, I guess it's the root folder for my app.. – Artem Kulikov May 12 '17 at 20:29

0 Answers0