Object Model Reference : Classes : V : View : Methods : View.Delete |
Sub Delete()
Member of View
The Delete method deletes a saved view from the View Manager.
The following VBA example deletes all views in the document.
Sub Test() |
Dim Vw As View |
Dim intCounter As Integer |
For intCounter = ActiveDocument.Views.Count To 1 Step -1 |
Set Vw = ActiveDocument.Views(intCounter) |
Vw.Delete |
Next intCounter |
Set Vw = Nothing |
End Sub |
Sub Test() |
Dim Vws As Views |
Set Vws = ActiveDocument.Views |
While Vws.Count <> 0 |
Vws(Vws.Count).Delete |
Wend |
Set Vws = Nothing |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.