Click here to Skip to main content
13,150,178 members (60,588 online)
Rate this:
 
Please Sign up or sign in to vote.
See more:
VS2008 development environment on 64-bit systems, I wrote two programs, a C # windows form program, reference a managed C + + dll, run the program results prompted an error FileLoadException error Exception from HRESULT: 0x800736B1

I see two programs solution platform is set anycpu,but it can run without problem when I solution platform is set to x86.
When I set to x64 mode, the performance was the same error of the situation anycpu mode.
What is the main reason of the problem?
Posted 19-Feb-13 18:42pm
Comments
   
You might have some component (native DLL, non-entry assembly) compiled to certain target instruction-set architecture. Everything depends on combination of target platforms and OS platform. You need to describe in more detail what do you have. I can explain you the idea, but don't waste too much time for something which might not be the case.
—SA
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

Please see my past answer to related question: application for all windows OS[^].

If this is not enough for you to understand things, to help you more, I would need more detail from you.

—SA
  Permalink  
Comments
peter462 21-Feb-13 2:14am
   
the problem is solved, thank you!
When I download depends tool, View the related dll depends, found missing the msvcp90.dll and several similar files.So from the C: \ Program Files (x86) \ Microsoft Visual Studio 9.0 \ VC \ redist \ amd64 copied to the need to file, the problem is solved.
   
Pleasure to help someone who actually can solve problems.
So, will you accept my answer formally then (green button)?

By the way, please remove the solution (or solutions) which are not answers but comments or question clarification. This is considered abuse; you can only get down-voted for them...

—SA
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 2

In the beginning I also think that is The dll program dependent on the external environment results in an error, but when I simplify the procedure to a minimum, the problem still exists
Simplified code is very simple:
c + + dll part:
#pragma once
 
using namespace System;
 
namespace CppDll {
 
    public ref class Class1
    {
        // TODO: Add your methods for this class here.
    };
}

win Form part:
public Form1()
{
    CppDll.Class1 cls = new CppDll.Class1();
    InitializeComponent();
}
  Permalink  
v2
Comments
peter462 20-Feb-13 3:09am
   
by the way my os is win7 64-bit systems.
peter462 20-Feb-13 3:23am
   
Processor: AMD Athlon(tm) II X2 245 Processor (2 CPUs)
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 3

the problem is solved, thank you!
When I download depends tool, View the related dll depends, found missing the msvcp90.dll and several similar files.So from the C: \ Program Files (x86) \ Microsoft Visual Studio 9.0 \ VC \ redist \ amd64 copied to the need to file, the problem is solved.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy |
Web03 | 2.8.170924.2 | Last Updated 21 Feb 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100