Adding Extended Data to Viewports AutoCAD

Adding Extended Data to Viewports AutoCAD

Anonymous
Not applicable
1,012 Views
1 Reply
Message 1 of 2

Adding Extended Data to Viewports AutoCAD

Anonymous
Not applicable

Hi 

 

I'm trying to add extended data to a viewport.  I've used the script below to sucessfully add extended data to Squares, Circles, Line..etc, BUT I'm having issues making it work with Viewports. Is there a way i can add extended data to viewports

 

Steps I followed

  1. Create Viewport as the last Object in the Drawing
  2. Run the below script in LISP Editor to add extended data to last object

 

 

(setq lastent (entget (entlast)))

(regapp "STV6")

(setq exdata
'((-3 ("STV6"
(1000 . "BLOCK_NAME")
(1000 . "DETAILCUT0")
)))
)

(setq newent
(append lastent exdata))

(entmod newent)

 

Thanks 

AJ

0 Likes
1,013 Views
1 Reply
Reply (1)
Message 2 of 2

artc2
Autodesk
Autodesk
You can't entmod a viewport. You can use the activex lisp functions to do it.

Here's an old thread about it:
https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/is-it-possible-to-add-eed-to-a-viewp...

I'm sure there are others.
0 Likes