+ Reply to Thread
Results 1 to 6 of 6
  1. #1
    Senior Member
    Discipline
    Architectural
    svorgodne's Discipline Details
    Occupation
    Architect. Lisp developer
    Discipline
    Architectural
    Using
    AutoCAD 2013
    Join Date
    May 2007
    Location
    Vienna, Austria
    Posts
    150

    Default define block with autolisp

    Registered forum members do not see this ad.

    Hello everyone,

    Is it possible to get with autolisp while running a block command, to get all possibilities that the normal block command has?

    When running the block command thru autlisp it only gives me two or three possibilities and not the one I need, which is the "convert to block", meaning make a block from selected objects and convert them immediately to a block.

    Thanks in advance
    Attached Images

  2. #2
    Luminous Being Tharwat's Avatar
    Discipline
    Mechanical
    Tharwat's Discipline Details
    Occupation
    MEP AutoCAD Draughtsman
    Discipline
    Mechanical
    Details
    HVAC, Drainage, Water Supply, Fire Fighting and a little about Electricity.
    Using
    AutoCAD 2015
    Join Date
    Oct 2009
    Location
    Great Syria , Living in Abu Dhabi
    Posts
    6,177

    Default

    Hi,
    Just erase and insert the same block once again in the same location.

  3. #3
    Quantum Mechanic Lee Mac's Avatar
    Computer Details
    Lee Mac's Computer Details
    Operating System:
    Win 7 Pro / Win 10 Pro / Linux Mint
    Discipline
    Multi-disciplinary
    Lee Mac's Discipline Details
    Discipline
    Multi-disciplinary
    Details
    Custom Programming / Software Customisation
    Using
    AutoCAD 2018
    Join Date
    Aug 2008
    Location
    London, England
    Posts
    19,533

    Default

    These examples may help you.
    Lee Mac ProgrammingTwitterExchange App StoreDropbox (500MB free)

    With Mathematics there is the possibility of perfect rigour, so why settle for less?

  4. #4
    Senior Member
    Discipline
    Architectural
    svorgodne's Discipline Details
    Occupation
    Architect. Lisp developer
    Discipline
    Architectural
    Using
    AutoCAD 2013
    Join Date
    May 2007
    Location
    Vienna, Austria
    Posts
    150

    Default

    Quote Originally Posted by Tharwat View Post
    Hi,
    Just erase and insert the same block once again in the same location.

    That's precisely, exactly what I want to avoid, because then the handles are changing and the block I try to make is only temporary, so if there are some attributes linked to some entities, like areas or so, then the link is lost because the polylines are new, so thanks a lot but that does not solve my problem.

    .-)

  5. #5
    Super Member
    Using
    not applicable
    Join Date
    Jun 2016
    Posts
    669

    Default

    @svorgodne:
    Have you ever verified this behavior? To my knowledge 'convert to block' creates a block definition with new entities, this block then gets inserted and the original entities are erased. Exploding the insert will again create new entities.
    Maybe you should look at creating a group instead?
    BricsCAD 18

  6. #6
    Senior Member
    Discipline
    Architectural
    svorgodne's Discipline Details
    Occupation
    Architect. Lisp developer
    Discipline
    Architectural
    Using
    AutoCAD 2013
    Join Date
    May 2007
    Location
    Vienna, Austria
    Posts
    150

    Default

    Registered forum members do not see this ad.

    Quote Originally Posted by Roy_043 View Post
    @svorgodne:
    Have you ever verified this behavior? To my knowledge 'convert to block' creates a block definition with new entities, this block then gets inserted and the original entities are erased. Exploding the insert will again create new entities.
    Maybe you should look at creating a group instead?

    Absolutely right Roy_043, didn't know that was happening. In any case, other parameters are missing when defining a block via autolisp. Hyperlink for example

    Thanks a lot

Similar Threads

  1. Block Autolisp
    By nicolas in forum AutoLISP, Visual LISP & DCL
    Replies: 2
    Last Post: 19th Jun 2012, 09:29 am
  2. How to get block name By Autolisp?
    By fathihvac in forum AutoLISP, Visual LISP & DCL
    Replies: 19
    Last Post: 13th Aug 2011, 05:15 am
  3. define more than one stretchable area in the same block
    By samifox in forum AutoCAD General
    Replies: 1
    Last Post: 4th Jul 2011, 02:22 pm
  4. How to define a function in AutoLISP with arbitrary arguments
    By Ahankhah in forum AutoLISP, Visual LISP & DCL
    Replies: 5
    Last Post: 24th Apr 2011, 06:54 pm
  5. Define Block Attributes with field name
    By gnotnoel in forum AutoCAD General
    Replies: 2
    Last Post: 20th Jun 2006, 06:57 pm

Bookmarks

Posting Permissions

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