PowerPoint嵌入YouTube视频
using System; using System.Collections.Generic; using System.Linq; using System.Text; using Microsoft.Office.Tools.Ribbon; using PowerPoint = Microsoft.Office.Interop.PowerPoint; namespace EmbedYouTubeVideo { public partial class Ribbon1 { private void Ribbon1_Load(object sender, RibbonUIEventArgs e) { } private void button1_Click(object sender, RibbonControlEventArgs e) { PowerPoint.Application PPaPP = Globals.ThisAddIn.Application; PowerPoint.Presentation Presentation = PPaPP.ActivePresentation; PowerPoint.CustomLayout layout = Presentation.SlideMaster.CustomLayouts[7]; PowerPoint.Slide Slide = Presentation.Slides.AddSlide(1, layout); PowerPoint.Shape Shape = Slide.Shapes.AddOLEObject(Left: 0, Top: 0, Width: 560, Height: 315, ClassName: "ShockwaveFlash.ShockwaveFlash.11"); var browser = Shape.OLEFormat.Object; browser.Movie = "http://www.youtube.com/v/wIH2LTxU3N8?version=3&hl=zh_CN&rel=0"; } } }相关资源:http://blog.csdn.net/tx_officedev/article/details/7449951
征诛志异,三让两家王朝;功同开辟,一桮万古江南。