Selection Set processing problems

Discussion in 'AutoCAD' started by Zachary, Aug 20, 2004.

  1. Zachary

    Zachary Guest

    Our office has a requirement to set our dashed/hidden/center lines up
    to work when a consultant changes the ltscale of the base drawings
    from our standard 1 to their standard 40. I thought that a good way
    to do this was to change all of the lines' ltscales down by 1/40th of
    their original.


    I have never worked with selection sets before and I am having some
    real difficulties getting the selection set to cycle through all the
    lines in the drawing

    I think that this gets all of the lines in the set.

    (setq zzSet (ssget "X" '((0 . "LINE"))))

    And the function below is working to change the ltscale of an
    individual entity.
    ( this uses a lib-dxf function out of "maximizing Autolisp" and Reini
    Urban's
    STDLIB)

    How can I feed one entity at a time to the change function?
    Any suggestions will be greatly appreciated.

    Zac.





    ;; Function to change the linetype scale on an entity
    ;; We assume that the ltscale of the drawing is set to 1 and
    ;; that it will be changing to a new scale factor
    ;;
    ;; example: a drawing changing from ltscale 1 to ltscale 40
    ;; (lib-convert-liene-lt 40 Entity)

    (DEFUN lib-convert-Line-lt (zzLT zzEnt )
    (setq zzlt (/ 1.000000 zzlt))

    (if (/= 1 (lib-dxf 48 zzEnt))
    (progn


    (setq zzFactor (* (lib-dxf 48 zzEnt) zzlt))
    (std-entchg zzEnt '("LINE") 48 zzFactor)


    ); End progn
    ); End if

    ); End defun
     
    Zachary, Aug 20, 2004
    #1
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.