This topic has not yet been rated - Rate this topic

IViewObject2 interface

Applies to: desktop apps only

An extension to the IViewObject interface which returns the size of the drawing for a given view of an object. You can prevent the object from being run if it isn't already running by calling this method instead of IOleObject::GetExtent.

Like the IViewObject interface, IViewObject2 cannot be marshaled to another process. This is because device contexts are only effective in the context of one process.

The OLE-provided default implementation provides the size of the object in the cache.

When to implement

Object handlers and in-process servers that manage their own presentations implement IViewObject2 for use by compound document containers.

When to use

A container application or object handler calls the IOleObject::GetExtent method in the IViewObject2 interface to get the object's size from its cache.

Members

The IViewObject2 interface inherits from IViewObject. IViewObject2 also has these types of members:

Methods

The IViewObject2 interface has these methods.

MethodDescription
GetExtent

Retrieves the size of the view object from the cache.

 

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

OleIdl.h

IDL

OleIdl.Idl

IID

IID_IViewObject2 is defined as 00000127-0000-0000-C000-000000000046

See also

IViewObject

 

 

Send comments about this topic to Microsoft

Build date: 3/7/2012

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ