ContainingPage property

Microsoft Visio Developer Reference

ContainingPage property

   Example   

Returns the page that contains an object.

Version added

4.0

Syntax

objRet = object.ContainingPage

objRet

The Page object that contains the object or collection.

object

Required. An expression that returns a Selection or Shape object or a Shapes collection to examine.

Remarks

If the object isn't in a Page object, the ContainingPage property returns Nothing. For example, if a Shape object belongs to a Masters collection, the ContainingPage property returns Nothing.