PowerPoint VBA教程:Patterned方法

将指定填充设为一种图案。

expression.Patterned(Pattern)

expression  必选。该表达式返回一个 FillFormat对象。

Pattern  必选。MsoPatternType 类型。用于指定填充的图案。

MsoPatternType 可以是下列 MsoPatternType 类型常数之一。
msoPattern10Percent
msoPattern20Percent
msoPattern25Percent
msoPattern30Percent
msoPattern40Percent
msoPattern50Percent
msoPattern5Percent
msoPattern60Percent
msoPattern70Percent
msoPattern75Percent
msoPattern80Percent
msoPattern90Percent
msoPatternDarkDownwardDiagonal
msoPatternDarkHorizontal
msoPatternDarkUpwardDiagonal
msoPatternDashedDownwardDiagonal
msoPatternDashedHorizontal
msoPatternDashedUpwardDiagonal
msoPatternDashedVertical
msoPatternDiagonalBrick
msoPatternDivot
msoPatternDottedDiamond
msoPatternDottedGrid
msoPatternHorizontalBrick
msoPatternLargeCheckerBoard
msoPatternLargeConfetti
msoPatternLargeGrid
msoPatternLightDownwardDiagonal
msoPatternLightHorizontal
msoPatternLightUpwardDiagonal
msoPatternLightVertical
msoPatternMixed
msoPatternNarrowHorizontal
msoPatternNarrowVertical
msoPatternOutlinedDiamond
msoPatternPlaid
msoPatternShingle
msoPatternSmallCheckerBoard
msoPatternSmallConfetti
msoPatternSmallGrid
msoPatternSolidDiamond
msoPatternSphere
msoPatternTrellis
msoPatternWave
msoPatternWeave
msoPatternWideDownwardDiagonal
msoPatternWideUpwardDiagonal
msoPatternZigZag
msoPatternDarkVertical

说明

使用BackColorForeColor属性设置图案使用的颜色。

VBA示例

本示例将一个带有图案填充的椭圆添加到myDocument


Set myDocument = ActivePresentation.Slides(1)
With myDocument.Shapes.AddShape(msoShapeOval, 60, 60, 80, 40).Fill
    .ForeColor.RGB = RGB(128, 0, 0)
    .BackColor.RGB = RGB(0, 0, 255)
    .Patterned msoPatternDarkVertical
End With

上页:PowerPoint VBA教程:PasteSpecial方法 下页:PowerPoint VBA教程:PickUp方法

PowerPoint VBA教程:Patterned方法

PowerPoint VBA教程:PickUp方法 PowerPoint VBA教程:Picture方法
PowerPoint VBA教程:Play方法 PowerPoint VBA教程:PointsToScreenPixelsX方法
PowerPoint VBA教程:PointsToScreenPixelsY方法 PowerPoint VBA教程:PresetDrop方法
PowerPoint VBA教程:PresetGradient方法 PowerPoint VBA教程:PresetTextured方法
PowerPoint VBA教程:Previous方法 PowerPoint VBA教程:PrevNode方法
PowerPoint VBA教程:PrintOut方法 PowerPoint VBA教程:Publish方法
PowerPoint VBA教程:Quit方法 PowerPoint VBA教程:Range方法
PowerPoint VBA教程:RangeFromPoint方法 PowerPoint VBA教程:Regroup方法
PowerPoint VBA教程:ReloadAs方法 PowerPoint VBA教程:Remove方法
PowerPoint VBA教程:RemoveBaseline方法 PowerPoint VBA教程:RemovePeriods方法
版权所有 © 中山市飞娥软件工作室 证书:粤ICP备09170368号