C# 如何在windows phone 8中打开.txt和.docx以及.xls文档

C# 如何在windows phone 8中打开.txt和.docx以及.xls文档,c#,windows-phone-8,isolatedstorage,app-launcher,C#,Windows Phone 8,Isolatedstorage,App Launcher,如何在windows phone 8中打开文本文档、.docx和.xls文档, 我将文件保存在独立存储中,然后尝试使用Launcher.FileAsync打开,但没有得到结果。有关更多信息,请参见下面的“我的代码”: string file = "Download.txt"; IsolatedStorageFileStream isfStream = new IsolatedStorageFileStream(file, FileMode.Create, IsolatedStorageF

如何在windows phone 8中打开文本文档、.docx和.xls文档, 我将文件保存在独立存储中,然后尝试使用Launcher.FileAsync打开,但没有得到结果。有关更多信息,请参见下面的“我的代码”:

  string file = "Download.txt";
  IsolatedStorageFileStream isfStream = new IsolatedStorageFileStream(file, FileMode.Create, IsolatedStorageFile.GetUserStoreForApplication());

        isfStream.Close();


        StorageFolder local = Windows.Storage.ApplicationData.Current.LocalFolder;
        StorageFile pdffile = await local.GetFileAsync(file);

        Windows.System.Launcher.LaunchFileAsync(pdffile);

GetFileAsync()
的语法是

public IAsyncOperation<StorageFile> GetFileAsync(string name)
这可能不被接受为相对路径。试一试

string file = @"\Download.txt";

检查,Karthik,我得到了解决方案,我在完全下载之前试着启动它。所以,它正在腐蚀它。我已经用后台下载程序完成了,然后启动它。谢谢
string file = @"\Download.txt";