Jump to content

how to select overried dimension ?qselect is not working


josemukalel

Recommended Posts

Please try this one,

 

(prompt "Ketik chkd untuk menjalankan program!")
(defun c:chkd (/ cd DimSel Pengulangan cnt Sdat EntDat DimGan )
(setq DimSel (ssget "_X" (list (cons 0 "Dimension")))); pemilihan objek khusus dimensi
(setq Pengulangan (sslength DimSel)); menghitung jumlah objek yang terpilih
(Setq cnt -1); membuat counter
(setq cd (ssadd))
;----------
(repeat Pengulangan
(setq cnt  (1+ cnt))
(setq Sdat (ssname DimSel cnt)); mengambil ename
(setq EntDat (entget Sdat))
(setq DimGan (cdr(assoc 1 EntDat))); mencari data dimensi yang diganti
(if (/= DimGan "")
(ssadd Sdat cd )

); if
); repeat
(command "select" cd)
(princ)
);defun
(princ)

 

regards,

 

Afri

Link to comment
Share on other sites

MMS

Thanks for this lisp

Could you please translate the sentences from your native lang to English?

 

I'm Sorry :), I will try for translate in English.

 

(prompt "Type CHKD for running program!")
(defun c:chkd (/ cd DimSel Pengulangan cnt Sdat EntDat DimGan )
(setq DimSel (ssget "_X" (list (cons 0 "Dimension")))); Selection set for Dimension
(setq Pengulangan (sslength DimSel)); calculating the selected object
(Setq cnt -1); Counter
(setq cd (ssadd))
;----------
(repeat Pengulangan
(setq cnt  (1+ cnt))
(setq Sdat (ssname DimSel cnt)); Get Ename
(setq EntDat (entget Sdat))
(setq DimGan (cdr(assoc 1 EntDat))); Searching Override Dimension
(if (/= DimGan "")
(ssadd Sdat cd )

); if
); repeat
(command "select" cd)
(princ)
);defun
(princ)

 

I'm from Indonesia so sometime I use Bahasa for create simple code.

 

Regards,

 

Afri

Link to comment
Share on other sites

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