PowerPoint) (FillFormat.UserPicture 方法
會以單一大圖像填滿指定的圖案。
語法
運算式。UserPicture (PictureFile)
表達 代表 FillFormat 物件的 變數。
參數
名稱 | 必要/選用 | 資料類型 | 描述 |
---|---|---|---|
PictureFile | 必要 | String | 圖片檔案名稱。 |
註解
如果您想要使用小型圖像並排顯示來填滿圖案,請使用 UserTextured 方法。
範例
在這個範例中,會將兩個矩形新增至 myDocument。 左邊的矩形會使用 Tiles.bmp 中的單一大型圖像填滿,而右邊的矩形則會使用 Tiles.bmp 中的小型圖片並排顯示填滿。
Set myDocument = ActivePresentation.Slides(1)
With myDocument.Shapes
.AddShape(msoShapeRectangle, 0, 0, 200, 100).Fill _
.UserPicture "c:\windows\tiles.bmp"
.AddShape(msoShapeRectangle, 300, 0, 200, 100).Fill _
.UserTextured "c:\windows\tiles.bmp"
End With
支援和意見反應
有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。