Skip to main content
Home Forums Silverlight Programming Silverlight Controls and Silverlight Toolkit Silverlight application and accessing client side files
5 replies. Latest Post by helena.munoz on November 27, 2009.
(0)
Ian Hannah
Member
0 points
6 Posts
11-27-2009 7:47 AM |
Hi,
I just wanted to make sure that my understanding was correct. When a client downloads a Silverlight application that application cannot access the client's file system other than by using a file open dialog. Is this correct?
So there is no way that the Silverlight application could read a configuration file from the client machine? What I would like to do is to have a standard installation but to allow the user to create a configuraition file that can be loaded. Any ideas on if this is possible or how to do it would be appreciated?
However in Silverlight 4 you can access the client file system if the application is run out of browser and has elevated privileges. Is this correct?
Thanks in advance
Ian
sl.ayer
Participant
848 points
162 Posts
11-27-2009 8:28 AM |
1) correct
2) You can save your configuration to isolated storage
3) trusted applications will have access to local file system
helena.m...
448 points
94 Posts
11-27-2009 9:37 AM |
You can allow the user to load a configuration file using OpenFileDialog. I guess that it would be the correct way to do it, because if you use isolated storate, the path to the file would not be user friendly.
11-27-2009 11:24 AM |
So are you saying that a trusted application that runs IN THE BROWSER will have access to the local file system in Silverlight 4? I was under the impression that this only works out of browser.
Thanks
11-27-2009 11:26 AM |
What I want to do is supply the Silverlight application with a set of initial configuration values. I guess that I cannot do this with isolated storage? As far as I can see isolated storage is ideal for saving settings for an application but not getting a set of initial settings.
11-27-2009 11:30 AM |
In Silverlight 3 you have a OpenFileDialg class that has acess to ANY part of the local file system, as long as the user selects the file using the dialog. (and yes, from the Browser) Because the user has control over what is going on, there are no major security problems there and Silverlights allows it.