Is this possible?

Discussion in 'AutoCAD' started by Jeffrey K. Ries, Feb 19, 2004.

  1. Can I set up a dwg file to display a message every time it is inserted as a
    block or x-ref?

    The reason being is to inform a user about issues which need to be
    customized upon inserting a standard detail from a library. In the past we
    have just put this info an a non-plot layer, but I thought this would be a
    better alternative.

    Thanks,
    Jeffrey K. Ries
     
    Jeffrey K. Ries, Feb 19, 2004
    #1
  2. Jeffrey K. Ries

    Guest Guest

    Jeffrey

    For xrefs, If it is possible to maintain a list containing all the relevant
    xrefs (DrawingList), the following should do the trick.

    (vlr-xref-reactor
    nil
    '(:)VLR-beginAttach . CheckXrefName))
    )

    (defun CheckXrefname (callingReactor XrefInfo / DrawingList)
    (setq XrefName (nth 1 XrefInfo))
    (setq DrawingList
    (list
    "C:\\YourDrawingPath\\YourDrawingName.dwg"
    "C:\\YourDrawingPath\\AnotherDrawingName.dwg"
    )
    )
    (if
    (member XrefName DrawingList)
    (progn
    (alert "Xref attached is in Master List")
    ;;Do your stuff here
    )
    )
    (princ)
    )

    Don't know about insertions though.

    Steve
     
    Guest, Feb 19, 2004
    #2
  3. Jeffrey K. Ries

    Guest Guest

    Jeffrey,

    You could use a commandended reactor to fire after an insert, then use
    (entlast) to interrogate the block to see if it's in the list also.

    Steve
     
    Guest, Feb 19, 2004
    #3
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.