Click here to Skip to main content
15,895,538 members
Home / Discussions / C#
   

C#

 
GeneralRe: Playout Video Pin
shakil ahmed21-Jul-06 21:00
shakil ahmed21-Jul-06 21:00 
QuestionControl events Pin
venkatchowdary21-Jul-06 1:34
venkatchowdary21-Jul-06 1:34 
QuestionVideo Streaming Problem Pin
shakil ahmed21-Jul-06 1:28
shakil ahmed21-Jul-06 1:28 
AnswerRe: Video Streaming Problem Pin
stancrm21-Jul-06 1:32
stancrm21-Jul-06 1:32 
AnswerRe: XMLReader Problem Pin
stancrm21-Jul-06 1:35
stancrm21-Jul-06 1:35 
QuestionProperties.Settings.Default.Save() does not work Pin
Mertli Ozgur Nevres21-Jul-06 1:06
Mertli Ozgur Nevres21-Jul-06 1:06 
AnswerRe: Properties.Settings.Default.Save() does not work Pin
Mertli Ozgur Nevres21-Jul-06 1:52
Mertli Ozgur Nevres21-Jul-06 1:52 
QuestionUnauthorizedAccessException Pin
sjembek20-Jul-06 23:55
sjembek20-Jul-06 23:55 
Hi,

I'm buidling a forms application in which user settings can be stored and loaded from a file. So far so good. Now I'm trying to load a file of this type made by another user on another computer. It seems this causes some kind security problem:

System.UnauthorizedAccessException: Access to the path 'C:\dotnet\myapp\bin\Debug\settings\defaults.set' is denied.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share)
at System.IO.File.Open(String path, FileMode mode)


The file in question is created simply as:

Stream stream = File.Open(filename, FileMode.Create);
BinaryFormatter bFormatter = new BinaryFormatter();
// serialize some stuff
stream.Close();


Why am I getting this error and does anyone know how to solve it?
AnswerRe: UnauthorizedAccessException Pin
leppie21-Jul-06 1:02
leppie21-Jul-06 1:02 
GeneralRe: UnauthorizedAccessException Pin
sjembek21-Jul-06 1:27
sjembek21-Jul-06 1:27 
GeneralRe: UnauthorizedAccessException Pin
leppie21-Jul-06 2:10
leppie21-Jul-06 2:10 
AnswerRe: UnauthorizedAccessException Pin
Vasudevan Deepak Kumar21-Jul-06 1:41
Vasudevan Deepak Kumar21-Jul-06 1:41 
GeneralRe: UnauthorizedAccessException Pin
sjembek21-Jul-06 2:06
sjembek21-Jul-06 2:06 
Questionnamevaluecollection in user settings Pin
Badscher20-Jul-06 23:22
Badscher20-Jul-06 23:22 
AnswerRe: namevaluecollection in user settings Pin
Badscher21-Jul-06 1:41
Badscher21-Jul-06 1:41 
AnswerRe: namevaluecollection in user settings Pin
LongRange.Shooter21-Jul-06 4:48
LongRange.Shooter21-Jul-06 4:48 
QuestionIsolatedStorageFile.GetStore() problem Pin
Super Lloyd20-Jul-06 23:12
Super Lloyd20-Jul-06 23:12 
AnswerRe: IsolatedStorageFile.GetStore() problem Pin
leppie21-Jul-06 2:22
leppie21-Jul-06 2:22 
GeneralRe: IsolatedStorageFile.GetStore() problem Pin
Super Lloyd21-Jul-06 3:17
Super Lloyd21-Jul-06 3:17 
QuestionHow do i check if an object can be cast to a valid SQLDbType? Pin
Red_Wizard_Shot_The_Food20-Jul-06 22:39
Red_Wizard_Shot_The_Food20-Jul-06 22:39 
AnswerRe: How do i check if an object can be cast to a valid SQLDbType? Pin
Robert Rohde20-Jul-06 22:46
Robert Rohde20-Jul-06 22:46 
GeneralRe: How do i check if an object can be cast to a valid SQLDbType? Pin
Red_Wizard_Shot_The_Food20-Jul-06 23:24
Red_Wizard_Shot_The_Food20-Jul-06 23:24 
AnswerRe: How do i check if an object can be cast to a valid SQLDbType? [modified] Pin
Martin#20-Jul-06 23:41
Martin#20-Jul-06 23:41 
GeneralRe: How do i check if an object can be cast to a valid SQLDbType? Pin
Robert Rohde20-Jul-06 23:52
Robert Rohde20-Jul-06 23:52 
GeneralRe: How do i check if an object can be cast to a valid SQLDbType? Pin
Red_Wizard_Shot_The_Food20-Jul-06 23:53
Red_Wizard_Shot_The_Food20-Jul-06 23:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.