Powerpoint(PPT) 2003和2007添加http开头的图片的问题解决
powerpoint 2003 直接 “AddPicture (http://” 可行,如:
- string pic = "http://bianbian.org/example.gif";
- _Slide.Shapes.AddPicture(pic, MsoTriState.msoFalse, MsoTriState.msoTrue,
- 0, 0, _Pres.PageSetup.SlideWidth, _Pres.PageSetup.SlideHeight);
但在ppt 2007中,无法通过AddPicture添加http开头的图片,必须先AddShape,然后Fill:
- PPT.Shape shape = _Slide.Shapes.AddShape(MsoAutoShapeType.msoShapeRectangle,
- 0, 0, _Pres.PageSetup.SlideWidth, _Pres.PageSetup.SlideHeight);
- shape.Fill.UserPicture(pic);
详见:http://support.microsoft.com/kb/928983/en-us