Jump to content

Recommended Posts

Posted

how to place incremental value like 0,10,20,30 or 0,9,18,27 in autocad

Posted
24 minutes ago, pmadhwal7 said:

how to place incremental value like 0,10,20,30 or 0,9,18,27 in autocad

 

basic of incremental , assume i= incremental value

(setq x (+ x i))

 

while

repeat

mapcar 

foreach

 

example: using repeat

(defun c:tt ( / i x)
(setq i 10 x 0)
(repeat 10
  (getstring "Press any key..")
  (princ (rtos (setq x (+ x i))2))
)
(princ)
)

 

Posted
4 minutes ago, hanhphuc said:

 

basic of incremental , assume i= incremental value


(setq x (+ x i))

 

while

repeat

mapcar 

foreach

 

example: using repeat


(defun c:tt ( / i x)
(setq i 10 x 0)
(repeat 10
  (getstring "Press any key..")
  (princ (rtos (setq x (+ x i))2))
)
(princ)
)

 

how can place those as a text

Posted

 

 

25 minutes ago, pmadhwal7 said:

how can place those as a text

 

 entmake or entmakex

(entmake (list '(0 . "TEXT") '(40 . 3) (cons 1 (rtos x 2) ) (list 10 0 x)) )

where should you put this line of code in previous code?

try it & learn

 

 

Posted
16 hours ago, hanhphuc said:

Sir i have an lsp which place incremental number like 1,2,3.... like this lsp can i din't get any lsp which palce 0,9,18,27, or 10,20,30

 

 

 entmake or entmakex


(entmake (list '(0 . "TEXT") '(40 . 3) (cons 1 (rtos x 2) ) (list 10 0 x)) )

where should you put this line of code in previous code?

try it & learn

 

 

 

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