Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
Valued Mentor
mdhutchinson
Posts: 2,320
Registered: ‎11-18-2003
Message 1 of 6 (414 Views)
Accepted Solution

layoutlist function

414 Views, 5 Replies
03-06-2013 03:18 PM

(layoutlist) ... returns a list of strings of the layout tabs in the drawing.

 

I've used this ages... Isn't it a core lisp function, or is it coming from express tools or somewhere else?

LayoutList is a core LISP function found in the developer documentation.

Distinguished Mentor
BlackBox_
Posts: 785
Registered: ‎02-25-2013
Message 2 of 6 (404 Views)

Re: layoutlist function

03-06-2013 04:14 PM in reply to: mdhutchinson

LayoutList is a core LISP function found in the developer documentation.



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security


AutoCAD® 2014, and Civil 3D® 2014 Certified Professional ~ Autodesk® Authorized Developer

Valued Mentor
mdhutchinson
Posts: 2,320
Registered: ‎11-18-2003
Message 3 of 6 (397 Views)

Re: layoutlist function

03-06-2013 05:18 PM in reply to: BlackBox_

I thought I recognized you from recent post concerning accorconsole.

acoreconsole says it is unknown function.

Distinguished Mentor
BlackBox_
Posts: 785
Registered: ‎02-25-2013
Message 4 of 6 (382 Views)

Re: layoutlist function

03-06-2013 08:58 PM in reply to: mdhutchinson

I see... I took the phrasing of your OP to mean "core" = basic, standard, vanialla AutoLISP (i.e. no Visual LISP, etc.), and not core console. 

 

Having read your recent post in your AcCoreConsole thread, this makes much more sense to me now... I'll be interested to see what becomes of it. 

 

Cheers!



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security


AutoCAD® 2014, and Civil 3D® 2014 Certified Professional ~ Autodesk® Authorized Developer

Valued Mentor
mdhutchinson
Posts: 2,320
Registered: ‎11-18-2003
Message 5 of 6 (362 Views)

Re: layoutlist function

03-07-2013 04:40 AM in reply to: mdhutchinson

I found what I needed... the below works in AcCoreConsole.

 

(defun GetLayoutListACoreConsole ()
 (defun massoc (key alist / x nlist)
  (foreach x alist
   (if (eq key (car x))
    (setq nlist (cons (cdr x) nlist))
   )
  )
  (reverse nlist)
 )
 (massoc 3 (dictsearch(namedobjdict)"acad_layout"))
)

Distinguished Mentor
BlackBox_
Posts: 785
Registered: ‎02-25-2013
Message 6 of 6 (350 Views)

Re: layoutlist function

03-07-2013 08:42 AM in reply to: mdhutchinson

Glad you got is sorted; thanks for posting the solution for others to find.

 

Here's wishing Autodesk would enbled full Visual LISP functionality for AcCoreConsole. *throws penny in wishing well*



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security


AutoCAD® 2014, and Civil 3D® 2014 Certified Professional ~ Autodesk® Authorized Developer

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.