Jump to content

In CAD VBA, Is there a way to see if a drawing is in the Acad editor.


Recommended Posts

Posted

AutoCAD 2006 or above.

 

Is there a way in VBA to test to see if the AutoCAD editor has a drawing

in it? Is there a way to tell if the Acad Editor is empty?

 

If there is more than one drawing in the acad editor how can you see which

one is the last loaded drawing.

 

At this time I need a answer for the first question .

 

Thank you,

Posted
AutoCAD 2006 or above.

 

Is there a way in VBA to test to see if the AutoCAD editor has a drawing

in it? Is there a way to tell if the Acad Editor is empty?

 

The Application.Documents.Count could be queried to see if it's 0.

 

If there is more than one drawing in the acad editor how can you see which

one is the last loaded drawing.

 

There may be other ways but one method could be to use an Application level event. Perhaps an EndOpen Event could log the most recent document in some globally scoped variable.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...