ProjectItem.BelongsTo operator

説明

オブジェクトが指定されたファミリに属している場合は True を、属していない場合は false を戻します。

スクリプト 構文

oBoolean = ProjectItem.BelongsTo( Family );

戻り値

Boolean

パラメータ

パラメータ タイプ 詳細
Family siFamilyまたは siFamily エレメントのArray 確認するファミリ(複数可)

VBScript の例

set oRoot = Application.ActiveProject.ActiveScene.Root
set oCube = oRoot.AddGeometry( "Cube", "MeshSurface" )
set oPrimitive = oCube.ActivePrimitive
if oPrimitive.BelongsTo(siGeometryFamily) then
        Application.LogMessage oCube.Name & " is a geometry object"
end if