Click here to Skip to main content
15,888,803 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all, i have a problem with my c++ RunPe.

I'm using native c++ as the stub, and i want to run from memory even native or managed exe.
If i run native exe my RunPe works fine, but if i try to run managed exe from memory my RunPe crash.

I want to use native c++ because my stub must run on almost all the 32 bit system and (using visual studio 2013) i cant use the /MT compiler options with /CLI so my resulting exe needs the visual studio runtime dll, dll not present in all the system.

If i use native c++ i can compile with /MT options.

I know it's possible to load the .net framework from native in run time.

Any ideas?
Posted
Comments
Sergey Alexandrovich Kryukov 7-Apr-14 19:04pm    
Not clear... Do you want to work in the setting where it's not guaranteed that .NET is installed. Because, if it is installed, there is nothing to "load". Or do you just want to use some .NET assemblies from the unmanaged code? This is possible, and even without those dreaded COM components...
—SA

1 solution

Hi Sergey and thanks for the reply.

So this is the situation :

the Stub is a 32 bit Win32 application (native).

if i put a native exe (32 bit console or Win32) in the stub (as resource) the stub can lanch the native exe from memory.
if i put a managed exe in the stub, i get ("Impossible to run application")

thanks!
 
Share this answer
 
Comments
Richard MacCutchan 9-Apr-14 9:25am    
I don't think you can run managed code in this way, as it needs to be loaded into the .NET framework.

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



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900