Results 1 to 5 of 5

Thread: Draw polyline and insert a fill circle

  1. #1
    Member
    Join Date
    2018-08
    Posts
    3
    Login to Give a bone
    0

    Default Draw polyline and insert a fill circle

    Hi all!
    I want to draw a polyline and insert in the first point an circle filled.
    Can you help me with a lisp code?
    Thanks

  2. #2
    All AUGI, all the time
    Join Date
    2003-07
    Posts
    560
    Login to Give a bone
    0

    Default Re: Draw polyline and insert a fill circle

    Use (setq pt (getpoint "\npick 1st point")) or if happy (setq pt (getpoint))

    Then Donut !pt enter inside and outside rads
    Then pline !pt then all the next pick points.

  3. #3
    Member
    Join Date
    2018-08
    Posts
    3
    Login to Give a bone
    0

    Default Re: Draw polyline and insert a fill circle

    Hi BIG-AL,
    this is my result:

    Code:
    (defun c:a3 (/ point)
    	(if (setq point (getpoint "\nSpecify start point: "))
    		(command "_.polygon" 4 "_non" point "_inscribed" 0.05))
    			(setq e1 (entlast))
    				(command "-.pedit" e1 "_w" 0.10 "_f" "") 
    					(command "_.pline" point)
      (princ)
    )
    I have another question: When i finish to draw the "pline", i want to add an "mtext" in the same position of the last vertex.
    How can i doing this?
    Thank you very much

  4. #4
    All AUGI, all the time
    Join Date
    2015-10
    Location
    Belgrade, Serbia, Europe
    Posts
    564
    Login to Give a bone
    0

    Default Re: Draw polyline and insert a fill circle

    @karmix,

    You need (progn ... ) after (if expression (progn ... then ) (progn ... else ));end if

    Next time, you test your code after posting...

    As for your question :

    ...
    (command "_.pline" "_non" point)
    (while (< 0 (getvar 'cmdactive))
    (command pause)
    )
    (command "_.text" "_non" (getvar 'lastpoint))
    (while (< 0 (getvar 'cmdactive))
    (command pause)
    )
    );end progn
    );end if
    (princ)
    );end defun

  5. #5
    Member
    Join Date
    2018-08
    Posts
    3
    Login to Give a bone
    0

    Default Re: Draw polyline and insert a fill circle

    Hi Marko,
    you think i can delete the "if" expression from my code?
    Your code do not run...
    Thank you

Similar Threads

  1. Replies: 1
    Last Post: 2013-01-28, 12:52 PM
  2. Dimension from face of circle to face of circle?
    By ljlange in forum Revit Architecture - General
    Replies: 1
    Last Post: 2009-10-18, 04:45 PM
  3. Distance from circle to circle
    By Brian.164262 in forum AutoLISP
    Replies: 8
    Last Post: 2008-04-24, 05:31 PM
  4. VBA project - draw a line of polyline, then insert a block
    By jbortoli in forum VBA/COM Interop
    Replies: 0
    Last Post: 2007-05-14, 08:01 AM
  5. Circle Polyline (ie Circle with Width)
    By johan d in forum AutoCAD General
    Replies: 4
    Last Post: 2006-02-03, 11:16 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •