viewports from objects

Discussion in 'AutoCAD' started by mnash, Jul 16, 2004.

  1. mnash

    mnash Guest

    Is there a way to only select the viewport entity (or filter the object entity) in a situation where the viewport is created from an object? Because when you select a viewport that has been created from an existing object, 2 objects are selected.
    I currently have a Lisp that modifies the viewport properties, but it won't let me perform the routine because there is another object tangled up with it.
     
    mnash, Jul 16, 2004
    #1
  2. mnash

    Jürg Menzi Guest

    Hi mnash

    This snipplet shows how to select the correct entity:

    <snip>
    (cond
    ((or (= (getvar "TILEMODE") 1) (> (getvar "CVPORT") 1))
    (alert " GetVpScale can only be done in paper space. ")
    )
    ((and
    (not (prompt "\nSelect Viewport... "))
    (not (setq SelSet (ssget "_:E:S" '((0 . "VIEWPORT"))))) ;<-- Here
    )
    )
    (T
    (DoYourStuff)
    )
    )
    <snip>

    Cheers
     
    Jürg Menzi, Jul 16, 2004
    #2
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.