In Browser Silverlight Application - Client Side File/Directory access

岁酱吖の 提交于 2020-01-07 05:04:31

问题


When building a Silverlight 4 application is it possible to get a directory listing from an in browser application?

It seems the SaveFileDialog does not have the capability to set the file name of the file being saved, so I thought that I could create my own user control, however it seems that is not possible as I can't get a directory listing in an in-browser application.

I realize that certain well known directories are accessible from Silverlight 4 in out-of-browser application, but that doesn't help an in-browser application.


回答1:


In-browser Silverlight apps are constrained by the sandbox, so from a file I/O perspective it's not much different from SL3 in the sense that you really have no access to the file system outside of Isolated Storage. Of course, a user can specify whatever directory they want to save a file in but you cannot specify it for the user - it's 100% the user's call on where a file is stored, and client-side file storage outside of Isolate Storage must be user-initiated.



来源:https://stackoverflow.com/questions/4167198/in-browser-silverlight-application-client-side-file-directory-access

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!