I have an issue with Silverlight application and SaveFileDialog. Basically I'm using SaveFileDialog in order to get from user path where he wants to save file and what is the file name. Then I'm passing that path to an API of other application(I'm using Silverlight 5 in Elevated Trust mode) which creates file for me.
Problem arise when user uses IE8 in Protected Mode.
SaveFileDialog.SafeFileName returns just a name of the file, not the path, and when I try to get that path with FileInfo, I'm getting always desktop no matter what user has selected.
I tried different approaches, including write just one byte into the file using stream from the SaveFileDialog.OpenFile - no success
I tried to access private member of SaveFileDialog.File.DirectoryName using reflection - property is marked with [SecurityCritical] so I cannot access...
I'm planning now to try invoke native browser save dialog using js in order to accomplish this but I'm not sure it will be different than Silverlight dialog.
Anyone out there smarter or more experienced than me around this problem? :)
Thanks