ProjectItem.Owners

説明

このオブジェクトの各オーナーの 1 つのProjectItemを含むProjectItemCollectionを戻します。ほとんどのオブジェクトのオーナーは 1 つだけですが、ブランチPropertyShader、およびOperatorオブジェクトのように共有されている場合もあります。

VBScript の例

'
' This example demonstrates how to find an object's owners
'
NewScene , false
set oRoot = Application.ActiveProject.ActiveScene.Root
set oGrid = oRoot.AddGeometry( "Grid", "MeshSurface" )
str = ""
for each oOwner in oGrid.Owners
        str = str & ", " & oOwner.Name
next
str = Right( str, Len(str)-2 )
Application.LogMessage "Object has owners : " & str
' Expected results:
'INFO : Object has owners : Scene_Root, Layer_Default, Background_Objects_Partition