Does ASPOSE Slides .NET have a feature of embedding a video file in a powerpoint? if so what formats are supported?
Can you please guide me to the dll which supports that and also the sample code.
Thanks
Sreedhar
Does ASPOSE Slides .NET have a feature of embedding a video file in a powerpoint? if so what formats are supported?
Can you please guide me to the dll which supports that and also the sample code.
Thanks
Sreedhar
Hi Sreedhar,
PresentationEx pres = new PresentationEx();VideoFrameEx vf = pres.Slides[0].Shapes.AddVideoFrame(110, 70, 100, 60, null);VideoEx vid = pres.Videos.AddVideo(new FileStream(@"…\Wildlife2.wmv", FileMode.Open)); // adding VideoEx from streamvf.EmbeddedVideo = vid;pres.Write(@"…\NewEmbed.pptx");
Thanks Fayyaz. It worked perfectly.
I have some more questions.
Can you please tell me what all video formats are supported in Aspose slides??
When I use the code above by default when I open the PPT the media shows as "No Image". Can I change this and put my own image there so that I can instruct the user to hover on it to see the play button at the bottom.
Also can you guide me to the documentation where I can get all the code samples (The latest document).
Thanks
Sreedhar
Hi Sreedhar,
PresentationEx pres = new PresentationEx();VideoFrameEx vf = pres.Slides[0].Shapes.AddVideoFrame(110, 70, 100, 60, null);VideoEx vid = pres.Videos.AddVideo(new FileStream(@“C:\Users\Public\Videos\Sample Videos\Wildlife.wmv”, FileMode.Open)); // adding VideoEx from streamvf.EmbeddedVideo = vid;//Set the pictureSystem.Drawing.Image img = (System.Drawing.Image)new Bitmap(@“C:\Users\Public\Pictures\Sample Pictures\Desert.jpg”);ImageEx imgx = pres.Images.AddImage(img);vf.FillFormat.FillType = FillTypeEx.Picture;vf.Image = imgx;// vf.FillFormat.PictureFillFormat.Picture.Image = imgx;pres.Write(@“D:\Aspose Data\NewEmbed.pptx”);
Thanks Fayyaz. It worked.
Can you point me to the latest Documentation for Aspose Slides for .NET.
Sreedhar
Hi Sreedhar,