Object Model Reference : Classes : V : View : Properties : View.OriginY |
Property OriginY As Double
Member of View
The OriginY property returns or specifies the value of the vertical origin of a view.
The following VBA example adds a view if there are no saved views. The vertical origins of all saved views are then displayed.
Sub Test() |
Dim Vw As View |
Dim VwCollection As Views |
Dim s As String |
Set VwCollection = ActiveDocument.Views |
If ActiveDocument.Views.Count = 0 Then |
VwCollection.AddActiveView "test" |
For Each Vw In VwCollection |
s = s & Vw.OriginY & vbCr |
Next Vw |
Else |
For Each Vw In VwCollection |
s = s & Vw.OriginY & vbCr |
Next Vw |
End If |
MsgBox "The vertical origin's of the saved views are: " & vbCr & s |
Set Vw = Nothing |
Set VwCollection = Nothing |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.