C# 从windows phone 8应用程序中的独立存储中读取和显示PDF文件
我想从独立存储中读取Pdf文件,并将其显示在Pdf查看器中。但据我所知,WindowsPhone8没有pdf控件。我是否可以使用任何第三方控件?或者是否有其他方式在Windows phone 8应用程序中显示pdf文件。您有三种途径:C# 从windows phone 8应用程序中的独立存储中读取和显示PDF文件,c#,pdf,windows-phone-8,pdf-viewer,C#,Pdf,Windows Phone 8,Pdf Viewer,我想从独立存储中读取Pdf文件,并将其显示在Pdf查看器中。但据我所知,WindowsPhone8没有pdf控件。我是否可以使用任何第三方控件?或者是否有其他方式在Windows phone 8应用程序中显示pdf文件。您有三种途径: 启动pdf,这将导致它在另一个应用程序中打开 为已经实现的控件付费,例如。注意他们是如何将一堆东西捆绑在一起的,这样你就不会只得到一个pdf查看器 制作自己的pdf查看器,这绝对是最难的方法 编辑: 如何启动与文件关联的应用程序: StorageFolder fo
StorageFolder folder = ApplicationData.Current.LocalFolder;
StorageFile file = await folder.GetFileAsync(<filename>);
Launcher.LauncheFileAsync(file);
StorageFolder folder=ApplicationData.Current.LocalFolder;
StorageFile file=wait folder.GetFileAsync();
LaunchFileAsync(文件);
您可以在任何需要的地方调用它。您有三条路线:
// get the assets folder for the app
StorageFolder folder = await Windows.ApplicationModel.Package.Current.InstalledLocation.GetFolderAsync("Folder");
// get the file included in app "Folder"
StorageFile file = await folder.GetFileAsync("test.pdf");
StorageFolder folder = ApplicationData.Current.LocalFolder;
StorageFile file = await folder.GetFileAsync(<filename>);
Launcher.LauncheFileAsync(file);
StorageFolder folder=ApplicationData.Current.LocalFolder;
StorageFile file=wait folder.GetFileAsync();
LaunchFileAsync(文件);
您可以在任何需要的地方拨打此电话。谢谢您的回复。但我想知道如何从AdobeReader或其他类似应用程序中的独立存储启动pdf文件。@Shivangi我编辑了我的回复,以包含关于此的说明。再次感谢。如果是一个独立的存储路径,这会起作用吗?@steveg89这段代码很有用,但我在打开excel文档时发现这段代码有错误。我遇到这样的错误,“Excel无法识别文件格式”。谢谢!!谢谢你的回复。但我想知道如何从AdobeReader或其他类似应用程序中的独立存储启动pdf文件。@Shivangi我编辑了我的回复,以包含关于此的说明。再次感谢。如果是一个独立的存储路径,这会起作用吗?@steveg89这段代码很有用,但我在打开excel文档时发现这段代码有错误。我遇到这样的错误,“Excel无法识别文件格式”。谢谢!!
// get the assets folder for the app
StorageFolder folder = await Windows.ApplicationModel.Package.Current.InstalledLocation.GetFolderAsync("Folder");
// get the file included in app "Folder"
StorageFile file = await folder.GetFileAsync("test.pdf");