API Documentation > CorelDRAW > 2025-v26 > Document > IVGDocument
Document.Active property
Returns True if the document is active
Syntax:
Property Get Active() As Boolean
Remarks:
The Active property returns True if the document is currently being edited by the user.
Examples:
The following VBA example displays the list of all documents currently open. Modified (and unsaved) documents display an asterisk ( * ) next to their names, and the current document is marked as Current.
Sub Test()
Dim d As Document
Dim s As String
s = "List of open documents:"
For Each d In Documents
  s = s & vbCr & "- " & d.Title
  If d.Dirty Then s = s & "*"

 If d.Active Then s = s & " (Current)"

 Next d

 MsgBox s
  
End Sub