CAB Posted August 2, 2009 Share Posted August 2, 2009 Here ya go. Layout Tab Select.LSP LayoutSelect.DCL Quote Link to comment Share on other sites More sharing options...
SteveK Posted August 2, 2009 Author Share Posted August 2, 2009 Ta! That's a good alternative. Quote Link to comment Share on other sites More sharing options...
CAB Posted August 3, 2009 Share Posted August 3, 2009 Glad you like it. I have never seen the TabSelected property exposed to LISP. Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 3, 2009 Share Posted August 3, 2009 Glad you like it. I have never seen the TabSelected property exposed to LISP. Put it on the wishlist I think vla-get-TabSelected Quote Link to comment Share on other sites More sharing options...
SteveK Posted August 11, 2009 Author Share Posted August 11, 2009 CAB, about your layout select program. I want to run it from another lisp to get the tab list. After I run it is there a way to retrieve the tablst variable? Or is setting tablst as a global variable the only way? Thanks. Quote Link to comment Share on other sites More sharing options...
CAB Posted August 11, 2009 Share Posted August 11, 2009 Steve, Use this version & it will return the list or nil if none selected. (defun GetTabList (/ dclfile dcl# layouts ptr tablist) (setq dclfile "LayoutSelect.dcl") (cond ((< (setq dcl# (load_dialog dclfile)) 0) ; Error (prompt (strcat "\nCannot load " dclfile ".")) ) ((not (new_dialog "layoutselect" dcl#)) ; Error (prompt (strcat "\nProblem with " dclfile ".")) ) (t ; No DCL problems: fire it up (setq layouts (vl-sort (layoutlist) '<)) (start_list "layouts") (foreach one layouts (add_list one) ) (end_list) (action_tile "layouts" "(setq ptr $value)") (action_tile "ok" "(done_dialog 5)") (action_tile "cancel" "(done_dialog 1)") (setq action (start_dialog)) (unload_dialog dcl#) (if (and ptr (= action 5)) ; get the list of selections to list of numbers (setq ptr (read (strcat "(" ptr ")")) tablist (mapcar '(lambda (x) (nth x layouts)) ptr)) ) ) ; end cond T ) ; end cond tablist ) Quote Link to comment Share on other sites More sharing options...
SteveK Posted August 11, 2009 Author Share Posted August 11, 2009 Thanks mate. Quote Link to comment Share on other sites More sharing options...
CAB Posted August 11, 2009 Share Posted August 11, 2009 You're quite welcome. Just after midnight here so I'll say good night, guess you're just getting up. Quote Link to comment Share on other sites More sharing options...
SteveK Posted August 11, 2009 Author Share Posted August 11, 2009 Getting up? Lol no it's the afternoon, I'm gearing up for home time. I think it would be Lee just getting up. Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 11, 2009 Share Posted August 11, 2009 haha, its great how "global" we all are Quote Link to comment Share on other sites More sharing options...
CAB Posted August 11, 2009 Share Posted August 11, 2009 Had to check time zones to see. http://24timezones.com/ Looks like Steve is 12+ hours ahead of me. Now he's off to sleep. Quote Link to comment Share on other sites More sharing options...
chulse Posted August 11, 2009 Share Posted August 11, 2009 Yes, it is a function defined in the ai_utils.lsp in the ACAD Support folder Try it at the command line Lee, I couldn't find that file anywhere - any Idea? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 11, 2009 Share Posted August 11, 2009 Type this at the command line: (findfile "ai_utils") Quote Link to comment Share on other sites More sharing options...
chulse Posted August 11, 2009 Share Posted August 11, 2009 it returned nil Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 11, 2009 Share Posted August 11, 2009 it returned nil Oh right - perhaps Civil 3D doesn't have it Quote Link to comment Share on other sites More sharing options...
chulse Posted August 11, 2009 Share Posted August 11, 2009 Was it part of the standard install for your version? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 11, 2009 Share Posted August 11, 2009 Yeah, standard install with ET Quote Link to comment Share on other sites More sharing options...
CAB Posted August 11, 2009 Share Posted August 11, 2009 Try this: (findfile "ai_utils.lsp") Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 11, 2009 Share Posted August 11, 2009 Try this:(findfile "ai_utils.lsp") Oops... yeah, I kinda forgot the extension Quote Link to comment Share on other sites More sharing options...
chulse Posted August 11, 2009 Share Posted August 11, 2009 That did it! Thanks! It was under "C:\\program files\\autocad civil 3d 2010\\support\\ai_utils.lsp" Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.