Dim aPView As
AcadPViewport
Dim aLayout As
AcadLayout
Dim i As
Long
'too lazy to work out the
bugs
On Error Resume Next
ThisDrawing.MSpace =
False
For Each aLayout In
ThisDrawing.Layouts
ThisDrawing.ActiveLayout = aLayout
If aLayout.Name <> "Model"
Then
For i
= 0 To ThisDrawing.PaperSpace.Count -
1
If TypeOf ThisDrawing.PaperSpace.item(i) Is AcadPViewport
Then
Set aPView =
ThisDrawing.PaperSpace.item(i)
aPView.Display
True
ThisDrawing.MSpace =
True
ZoomExtents
ThisDrawing.MSpace =
False
aPView.DisplayLocked =
True
End If
Next
End If
Next
there may be more elegant ways to go about this,
time permitting...
Kevin
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
How
can I turn on every viewport on very layout tab, zoom to extents, and then
lock it?
Thanks,
Troy