Previous Document Next Document
ActiveView.ToFitShape

Sub ToFitShape(Shape As Shape)

Member of ActiveView

The ToFitShape method changes the active view to fit an entire shape in the current document into the application window. This method adjusts the zoom level of the page so that the specified shape fills the current view in the application window.

Parameters
Description
Shape
Specifies the shape object that you want to zoom out

The following code example creates a circle in CorelDRAW and adjusts the active view to zoom in on the circle in the active document.

Sub ToFitShape() 
 Dim s As Shape 
 Set s = ActiveLayer.CreateEllipse2(5, 5, 2) 
 ActiveWindow.ActiveView.ToFitShape s 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.