Download File using Sliverlight

793
5
07-19-2011 03:42 AM
LakshmananVenkatesan
Occasional Contributor II
This is purely sliver light question, how to download the file in the web server. On button click, I just need to download the file with "Save as/Open/Cancel" options. I do not want to open another hyperlink/server page. I am using sliverlight 4.0 version.
0 Kudos
5 Replies
JenniferNery
Esri Regular Contributor
0 Kudos
LakshmananVenkatesan
Occasional Contributor II
I want to download the file directly on button click . I have lot of pdf files stored in web server path is ex. http://webservercomputer/arcgisjobs/print1.pdf . On click of button, I want download this file to the user computer . Hope am clear with the requirement
0 Kudos
IgressT
New Contributor II
how about using System.Net.WebClient class
0 Kudos
HugoCardenas
New Contributor
You can't if you are running the Silverlight application from a web page.  You could if you run the Silverlight application with the "out of the browser" setting.  I tried it this week; however, I refused to convert my browser-based application in an "out of the browser" one.

I am writing a WCF service - a standard .NET library (dll) which will do the job for me.  I tried a Silverlight WCF, but it fails as well, for Silverlight does not clearance to write to the file system.  Once I am done with my new standard WCF service, I can give you a copy of the dll and source code.

Hugo.
0 Kudos
IgressT
New Contributor II
Can you save the file to the isolated storage?
0 Kudos