Skip to main content
Home Forums Silverlight Programming Programming with JavaScript Opening Local Files with Javascript or C#
1 replies. Latest Post by SharpGIS on June 20, 2009.
(0)
FuryDiamond
Contributor
3928 points
781 Posts
06-19-2009 3:25 PM |
I am having problems opening Office 2003 (xls, doc, and ppt extensions) and 2007 files (xlsx, docx, pptx extensions) using Javascript. The following code works for non-Office files and html pages. It works when running on localhost or a remote server, but if you are testing on the hard drive or usb drive, it doesn't. Any suggestions? Is there a way to have them open the files?
function gotoPage(page) { window.open(page); } function gotoPage2(page) { window.location = page; }
Or is it possible to open the file in the Silverlight C# backend?
SharpGIS
3387 points
611 Posts
06-20-2009 5:04 PM |
No this is not possible and you shouldn't be doing this. This is not a limitation caused by Silverlight either.