.NET migration

H

High and dRy

I have the C++ exe created with Microsoft Visual Studio 6.0. Now have
ported the code to Microsoft Visual Studio 7.0. to compile with /clr
extension ON; as the exe uses some managed code components.

The project compiles fine in both Debug and Release version. It also
runs perfectly in both versions if I run the exe directly from windows
explorer.

But when I try to run the Release version from the IDE, it gives me
the following error message:
An unhandled exception of type 'System.Security.Policy.PolicyException' occurred in Unknown Module.
Additional information: Unverifiable assembly
's:\AppSrc\Fe\ToolsSimulator\Release\ToolsSimulator.exe' failed policy
check


If I try to run the Debug version through the IDE the app crashes at:
GetClientRect(rect) at void CRichEditView::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags).


Any suggestion will be very helpful.

Thanks,
~Saurabh
 
W

Willy Denoyette [MVP]

I'm sure you will get more help when posting VC++ questions to - microsoft.public.dotnet.languages.vc
Your code need an highly trusted environment to run, do you happen to run this from a network share?

Willy.
 
S

saurabh boyed

No its locally on my computer. I wonder why it runs just fine when I
directly execute the standalone exe. And it does not run from the IDE.
May be I have to do some security settings.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top