Private Sub ZoomWindow_Example()
' This example creates a line and adds it to the drawing using the AddLine
' method. It then uses the ZoomWindow method to zoom in on a window.
Dim myDoc As IntelliCAD.Document
Dim myLine As IntelliCAD.Line
Dim myStartPt As IntelliCAD.Point
Dim myEndPt As IntelliCAD.Point
Dim PtLL As IntelliCAD.Point
Dim PtUR As IntelliCAD.Point
Set myDoc = Application.ActiveDocument
Set myLine = myDoc.ModelSpace.AddLine(Library.CreatePoint(4, 4), Library.CreatePoint(7, 1))
Set PtLL = Library.CreatePoint(0, 0, 0)
Set PtUR = Library.CreatePoint(10, 10, 0)
myLine.Update
Me.hide
ThisDocument.ActiveViewport.ZoomWindow PtLL, PtUR
End Sub