tags:

views:

53

answers:

1

Hi,

I have a problem with a command button (implementing the ICommand). I want, when pressing the specified button to redirect the user at new tab targeting a UNC path.

HtmlPage.Window.Navigate(new Uri(@"\\host\filename"), "_blank");

The problem is that browser redirects the user to the following target, besides of my intention:

http://www.hostnameoftheslapplication.com/\\host\filename

How can I achieve the correct navigation;

Thank you in advance.

A: 

What you are trying to do is not allowed in Silverlight. HTML navigation is for opening web pages from web servers, but the UNC syntax you are providing is for file system access. Silverlight only allows extrememly limited access to the filesystem of the client PC.

To be able to serve up your file, you could configure your web server so that the "host" path was a virtual directory within your web application. Then you could use relative URI syntax to serve up the filename rather than UNC syntax.

Tim Trout
Navigating to a url, through browser's DOM? It is the same as if I open manually the UNC path file://dldld/lddldl.avi. Instead, I am doing it through Silverlight. After the redirect is made, the browser takes action.
Aggelos Mpimpoudis