473,320 Members | 1,881 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.

IO Permission Error, Form Won't Load

I have an object on my form the does reading from a file and another
that writes to a file. Simple operation just Readline()/Writeline().
I had a problem previously where my form would throw up an error on
run (not build).

An error occurred creating the form. See Exception.InnerException for
details. The error is: Request for the permission of type
'System.Security.Permissions.FileIOPermission, mscorlib,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
failed.

I copied the code into a new solution and it worked until I saved it
at which point it promptly broke. It originally saved onto a network
drive, I've tried copying it to the desktop because I know .NET has
network drive issues. Any suggestions on fixing this are much
appreciated.

Also note that the exception is not stopping on a line it just stops
immediately upon run. All the files are defined by the user via
OpenFileDialog. I've tried commenting out all the line containing the
streamreader/streamwriter with no affect.

Oct 5 '07 #1
1 1641
Alrighty, after working on it for a while I had an epiphany and
managed to fix the problem by moving the file locally (desktop I found
is not local). It now works but that does not explain why it was
breaking on load. If anyone has any suggestions on that portion of it
I would be happy to hear it since I'll have to move it back to a
network location once I'm done.

Oct 5 '07 #2

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

Similar topics

3
by: msnews.microsoft.com | last post by:
I'm running a intranet site on a NT 4.0 IIS 4 server. I have a page that uses CDONTS. I recently change this intranet application to run as an isolated process (Selecting the checkbox "Run in...
2
by: Gustavo L. Fabro | last post by:
Greetings. I had an user control built on Visual Studio 2003 that I used in some forms build also with Visual Studio 2003 (C++ was the language for both cases). Now I'm trying to port this to...
12
by: Russ | last post by:
Hello. My new dev machine is running XP Pro. In the past all equipment has only used Windows 2000. I have had a lot of problems getting my projects up and running on the new machine. The current...
10
by: Florian G. Pflug | last post by:
Hi I installed a postgres-application (which was developed on debian woody) on red hat 9 today, using the postgres 7.3 rpms from redhad. One of my the triggers uses the pg_settings table (more...
0
by: David Berman | last post by:
Hello, I'm receiving an error reading the machine.config file when I try to access my web application. This error came out of nowhere. After searching many sites, googelizing and searching here,...
6
by: Angel | last post by:
I am using coolmenus 4, frames version by DHTMLcentral.com. When I click on any of the submenus, I get an "Permission Denied" error. There after the menus stop working. The cursor on the menu...
25
by: Blasting Cap | last post by:
I keep getting errors that pop up when I am trying to convert an application from dotnet framework 1.1 to framework 2.0. The old project was saved in sourcesafe from Visual Studio 2003, and I have...
5
by: TimSki | last post by:
Hi, I have an iframe on my page which calls an external website. When the page loads in firefox i see a 'Error: Permission denied to call method Location.toString' in the error console but the...
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: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
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: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
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.