Jump to content

New command button to open a template


Recommended Posts

Posted

does anyone know how i can open an existin drawing from a button or pull down? I need the script

Posted

Well you can get a menu that will open a drawing by pressing

"Ctrl-O" if you have it set as default value for it.

 

"Ctrl-N" gives you a new drawing

  • 4 years later...
Posted

i too am looking to do this..... the above link is helpful but the solution is a lisp code. rkmcswain says

 

Try this:

 

(vlax-invoke-method
   (vla-open
    (vla-get-Documents
      (vlax-get-acad-object)
    )
    "C:\\BBBB.DWG"
  )
 "Activate"
) 

is it possible to put this in a macro, or attach this code to a button?

thanks all

Posted

or how would i add a definition to the beginning of this so i can run it from a command?

 

i've not seen a lsp like this before that runs automatically - i would expect to load it first, then use a command to run it?

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...