Jump to content

Recommended Posts

Posted

LOOKING FOR A LISP FILE FOR THE FOLLOWING:

While object is selected

PULL DOWN MENU, EDIT

COPY W/ BASEPOINT (_copybase)

_copybase Specify Base Point: 0,0

command: e

PULL DOWN MENU, EDIT

PASTE AS BLOCK

(_pasteblock Duplicate definition of Block _oblique ignored.)

Specify Insertion Point: 0,0

command: _LayerP

Posted

Quick and dirty:

 

(defun c:pstblk (/ *error* vl ov ss)

 (defun *error* (msg)
   (if ov (mapcar 'setvar vl ov))
   (if
     (not
       (wcmatch
         (strcase msg) "*BREAK,*CANCEL*,*EXIT*"))
     (princ
       (strcat "\n<< Error: " msg " >>")))
   (princ))

 (setq vl '("CMDECHO" "OSMODE")
       ov (mapcar 'getvar vl))
 (mapcar 'setvar vl '(0 0))

 (if (setq ss (ssget))
   (progn
     (command "_.copybase" '(0 0 0) ss "")
     (command "_.pasteblock" '(0 0 0))
     (command "_.erase" ss "")))

 (mapcar 'setvar vl ov)
 (princ))

Posted

thanks lee, works good will save me some time here, thanks again

Posted
thanks lee, works good will save me some time here, thanks again

 

No probs mate :)

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