0

I have a file in my IsolatedStorage. I need to open the file from my application. I tried to open it in WebBrowser like this

private void OpenFile(string url)
{
    WebBrowserTask task = new WebBrowserTask();
    task.Uri = new Uri(url);
    task.Show();
}

but it throws an exception. The error message is Invalid URI: The format of the URI could not be determined.

How can I open the file in my application?

PedroC88
  • 3,571
  • 7
  • 43
  • 72
Nelson T Joseph
  • 2,553
  • 7
  • 36
  • 53

1 Answers1

1

See : Local HTML File - WebBrowser - Windows phone 7 You must use NavigateToString method : http://msdn.microsoft.com/en-us/library/system.windows.controls.webbrowser.navigatetostring.aspx

Community
  • 1
  • 1
Julien
  • 3,479
  • 19
  • 35
  • Thanks for your reply. I have files of type pdf,doc,xls,ppt,txt or an image. I need to open the one which is selected by user. Just need to open it, in browser or in any other way. – Nelson T Joseph Mar 01 '12 at 12:03