473,320 Members | 1,982 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

MFC exe Crashes with /clr option

I have a MFC app that was developed with VC++ 2003 7.1 . I have now
upgraded to VC++ 2005 8.0. Eventually I plan on using a Windows Form
Control and hosting it on existing dialog.

1) First I compiled the project in 2005 and fixed a few errors and am
able to compile/run with seemingly no problems

2) I turned on the /clr option and fixed what ever problems and now am
able to compile with no errors

2a) now when I run I get a crash. My project settings are:

<Tool
Name="VCCLCompilerTool"
Optimization="0"

AdditionalIncludeDirectories="&quot;$(SolutionDir) \common\include&quot;;&quot;$(SolutionDir)\DataRec order&quot;;&quot;$(BOOST_INC_MSVC)&quot;"
PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_SC L_SECURE_NO_DEPRECATE;"
GeneratePreprocessedFile="0"
BasicRuntimeChecks="0"
RuntimeLibrary="3"
RuntimeTypeInfo="true"
UsePrecompiledHeader="1"
PrecompiledHeaderThrough="stdafx.h"
PrecompiledHeaderFile=".\Debug/pdr2.pch"
AssemblerListingLocation=".\Debug/"
ObjectFile=".\Debug/"
ProgramDataBaseFileName=".\Debug/"
BrowseInformation="1"
WarningLevel="4"
SuppressStartupBanner="true"
DebugInformationFormat="3"
/>
The error from the crash is:

First-chance exception at 0x7c81eb33 in Data Recorder.exe: Microsoft
C++ exception: [rethrow] at memory location 0x00000000

An unhandled exception of type 'System.IO.FileLoadException' occurred
in Unknown Module.

Additional information: Could not load file or assembly 'Data Recorder,
Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its
dependencies. Failed to grant minimum permission requests. (Exception
from HRESULT: 0x80131417)

I have tried placing try/catch blocks around the CWinApp::InitInstance,
CWinApp::InitApplication, and CWinApp::Run and I don't think the
program ever reaches any of these functions.

If anyone can help me, please do.
Thanks in advance for the help.

Jul 14 '06 #1
2 1724
I forgot to mention that my MFC app is located on a remote computer
(intranet) and I'm running it from my computer.
Jacquie wrote:
I have a MFC app that was developed with VC++ 2003 7.1 . I have now
upgraded to VC++ 2005 8.0. Eventually I plan on using a Windows Form
Control and hosting it on existing dialog.

1) First I compiled the project in 2005 and fixed a few errors and am
able to compile/run with seemingly no problems

2) I turned on the /clr option and fixed what ever problems and now am
able to compile with no errors

2a) now when I run I get a crash. My project settings are:

<Tool
Name="VCCLCompilerTool"
Optimization="0"

AdditionalIncludeDirectories="&quot;$(SolutionDir) \common\include&quot;;&quot;$(SolutionDir)\DataRec order&quot;;&quot;$(BOOST_INC_MSVC)&quot;"
PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_SC L_SECURE_NO_DEPRECATE;"
GeneratePreprocessedFile="0"
BasicRuntimeChecks="0"
RuntimeLibrary="3"
RuntimeTypeInfo="true"
UsePrecompiledHeader="1"
PrecompiledHeaderThrough="stdafx.h"
PrecompiledHeaderFile=".\Debug/pdr2.pch"
AssemblerListingLocation=".\Debug/"
ObjectFile=".\Debug/"
ProgramDataBaseFileName=".\Debug/"
BrowseInformation="1"
WarningLevel="4"
SuppressStartupBanner="true"
DebugInformationFormat="3"
/>
The error from the crash is:

First-chance exception at 0x7c81eb33 in Data Recorder.exe: Microsoft
C++ exception: [rethrow] at memory location 0x00000000

An unhandled exception of type 'System.IO.FileLoadException' occurred
in Unknown Module.

Additional information: Could not load file or assembly 'Data Recorder,
Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its
dependencies. Failed to grant minimum permission requests. (Exception
from HRESULT: 0x80131417)

I have tried placing try/catch blocks around the CWinApp::InitInstance,
CWinApp::InitApplication, and CWinApp::Run and I don't think the
program ever reaches any of these functions.

If anyone can help me, please do.
Thanks in advance for the help.
Jul 14 '06 #2
Hi Jacqui!
I forgot to mention that my MFC app is located on a remote computer
(intranet) and I'm running it from my computer.
>>Failed to grant minimum permission requests. (Exception
As the error message mentions: You have no permission to execute this
EXE/DLL from a network share.

--
Greetings
Jochen

My blog about Win32 and .NET
http://blog.kalmbachnet.de/
Jul 15 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: greeningster | last post by:
I have written an application in Visual C++ for a customer but it seems to crash randomly. Could anyone give me any help on how I could track this down ? Also, there appears there might be...
2
by: Ray | last post by:
Stop me if you've heard this, but I am running Access 2002 and all of a sudden, if I design a particular form (it's been working fine for ages), Access crashes rather than open it in design view. ...
13
by: Chris Stankevitz | last post by:
You guys are going to like this. I work on a very large (500,000 line) native C++ project. VS started crasing recently and I've similified it down to fifty lines (took me six hours). Why is...
1
by: Andrew Clancy | last post by:
Hi, I've got a small prob with my Visual Studio setup - seems to happen in both Visual Studio & VS.Net. The inital setup screen comes up, but when I choose the 1st option (Install Visual Studio...
8
by: mike2036 | last post by:
I have an application (that has unmanaged code) and when I launch it without 'FullTrust' permissions (LocalIntranet_Zone), it crashes. When I set 'FullTrust' permissions, it launches fine. Is...
4
by: mr.fullzero | last post by:
Our team have extracted code sample that caused abnormal Safari termination. The crash seems to happen any time, when user selects an option and closes alert popup. The version of Safari is 10.4.6....
41
by: z | last post by:
I use Visual C 2005 to develop my programs. One in particular is crashing in very specific and hard to replicate situations, made worse by the fact it only crashes when run -outside- the dev - as...
2
by: tsahiasher | last post by:
the following code crashes my csc.exe (visual studio 2005): project Base references: System BaseClass.cs: namespace Base { public class BaseClass<T> { public void BaseFunc()
2
by: curran.george | last post by:
'add one textbox to form1 with Control Source property = ID 'copy/paste the form_load code below: 'Then open the form and then attempt to sort the datasheet 'crashes 2003, error 3450 Access 2007 -...
2
by: Dave Johansen | last post by:
I just converted a solution from Visual Studio 2003 to Visual Studio 2005 and the Debug mode seems to be running just fine, but the Release mode crashes on the following code: std::ifstream...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.