Go Premium for a chance to win a PS4. Enter to Win


Unable to Run Exe from Another PC

Posted on 2007-09-08
Medium Priority
Last Modified: 2012-06-27
I have created a Windows based App and is able to run on my own PC (PC A).
Afterwhich, I moved the exe to another PC (PC B) and shared the directory.
At PC A, I map a drive to the directory (V:\).
At another PC (PC C) I also map a V:\ to the directory in PC B.

One weird problem I encountered is on PC C, I am able to run V:\myexe.exe successfully.
However, on PC A, I encounter a runtime error as below

"Request for permission of type 'System.Security.Permissions.EnvironmentPermission, mscorlib, version=, Culture=neutral, PublicKeyToken=bb77a5c561934e089' failed".
Question by:ee_guest
  • 2
LVL 33

Accepted Solution

hongjun earned 500 total points
ID: 19855099
Try this

Start -> Control Panel -> Administrative Tool -> Microsoft .NET Framework Configuration
Open Configure Code Access Security Policy -> Adjust Zone Security -> Make changes to this computer.
Give Full Trust for My Computer and Local Intranet.

LVL 11

Expert Comment

ID: 19856318
1. Choose Start -> Control Panel -> Administrative Tools -> Microsoft .NET Framework 1.1 Wizards
2. Choose Trust an Assembly
3. Choose whether you want to make changes for the computer or current user and click Next
4. Enter the UNC location of the application you want to run and click Next
5. Click Next to trust just this assembly
6. Adjust the slider to Full Trust and click Next
7. Click Finish

R u trying access wny Environment variable from ur application??

Author Comment

ID: 19856324
I am trying to get computer name.
I will try when the week starts on monday.
LVL 11

Expert Comment

ID: 19857313
How u r getting the Computer Name??

Featured Post

Learn Veeam advantages over legacy backup

Every day, more and more legacy backup customers switch to Veeam. Technologies designed for the client-server era cannot restore any IT service running in the hybrid cloud within seconds. Learn top Veeam advantages over legacy backup and get Veeam for the price of your renewal

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

783 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question