Asp.net mvc 2 如何在ASP.NET应用程序中查看PowerPoint?

Asp.net mvc 2 如何在ASP.NET应用程序中查看PowerPoint?,asp.net-mvc-2,asp.net-2.0,powerpoint,viewer,Asp.net Mvc 2,Asp.net 2.0,Powerpoint,Viewer,有人有我可以嵌入ASP.NET Web应用程序的PowerPoint viewer吗?如果您使用Silverlight,您可以使用 您不能直接嵌入要查看的PPT/演示文稿。相反,您可以尝试任何转换器,该转换器允许您将PPT幻灯片嵌入为图像或客户端浏览器可以呈现给用户的其他格式。很少有像GroupDocs viewer或DoCoUnit viewer这样的产品能够做到这一点。您可以试一试。您必须将PowerPoint幻灯片转换为可嵌入网页的格式,即图像或HTML页面。您可以尝试将演示幻灯片呈现为

有人有我可以嵌入ASP.NET Web应用程序的PowerPoint viewer吗?

如果您使用Silverlight,您可以使用


您不能直接嵌入要查看的PPT/演示文稿。相反,您可以尝试任何转换器,该转换器允许您将PPT幻灯片嵌入为图像或客户端浏览器可以呈现给用户的其他格式。很少有像GroupDocs viewer或DoCoUnit viewer这样的产品能够做到这一点。您可以试一试。

您必须将PowerPoint幻灯片转换为可嵌入网页的格式,即图像或HTML页面。您可以尝试将演示幻灯片呈现为高保真图像(PNG/JPG)或HTML页面。然后,可以将呈现的页面嵌入到网页中以预览幻灯片。以下是渲染幻灯片的方式:

渲染为图像:

以HTML格式呈现:

披露:我在GroupDocs担任开发人员宣传员

using GroupDocs.Viewer.Options;

// Set output path 
string OutputPagePathFormat = Path.Combine("C:\\output", "page_{0}.png");
// Render document pages
using (Viewer viewer = new Viewer("C:\\sample.pptx"))
{
    PngViewOptions options = new PngViewOptions(OutputPagePathFormat);
    viewer.View(options);
    // Rendered images will be saved in the D:\output\ directory.
}
using GroupDocs.Viewer.Options;

// The file path format 
string OutputPagePathFormat = Path.Combine("C:\\output","page-{0}.html");
using (Viewer viewer = new Viewer("C:\\sample.pptx"))
{       
   HtmlViewOptions options = HtmlViewOptions.ForEmbeddedResources(OutputPagePathFormat);
   viewer.View(options);
}