Shape.IsInline 属性 (Publisher)

返回一个 MsoTriState 常量,该常量指定形状是否为内联 (包含在文本运行) 中。 此为只读属性。

语法

表达式IsInline

expression 一个代表 Shape 对象的变量。

示例

本示例检测嵌入出版物第一页上第一个形状 (一个文本框)。 如果不是,是要查找的文字框架中的嵌入形状,形状中进行搜索。 找到所有内嵌形状都具有 前景色 属性设置为红色。

Dim theShape As Shape 
Dim i As Integer 
 
Set theShape = ActiveDocument.Pages(1).Shapes(1) 
 
If Not theShape.IsInline = True Then 
 With theShape.TextFrame.Story.TextRange 
 If .InlineShapes.Count > 0 Then 
 For i = 1 To .InlineShapes.Count 
 .InlineShapes(i).Select 
 .InlineShapes(i).Fill.ForeColor.RGB = vbRed 
 Next 
 End If 
 End With 
End If

支持和反馈

有关于 Office VBA 或本文档的疑问或反馈? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。