elfert Posted May 13, 2015 Posted May 13, 2015 I need a command or a short lisp routine to set a ctb file on a open drawing. Is that possible? I need this because i have alot of drawings where I need to set the correct customer CTB file on each drawing and instead of doing a manual job i want to able to do it by a script on a lot of drawings. Please help! Thx in advance! Quote
rkmcswain Posted May 13, 2015 Posted May 13, 2015 First you said you want to do it on an "open drawing", then you said you want to "do it by a script on a lot of drawings" Is that two separate wishes or did I misunderstand? Quote
rkmcswain Posted May 13, 2015 Posted May 13, 2015 Also, do you need to apply the plot style to model space, or a single layout, or multiple layouts or all of the above? Quote
rkmcswain Posted May 13, 2015 Posted May 13, 2015 Here is some sample code (no error checking) that will set the plot style in the current layout in the current drawing. (setq *acad-object* (vlax-get-acad-object)) (setq *active-document* (vla-get-activedocument *acad-object*)) (setq *active-layout* (vla-get-activelayout *active-document*)) (vla-put-stylesheet *active-layout* "mycustom.ctb") 1 Quote
BlackBox Posted May 13, 2015 Posted May 13, 2015 This recent thread may be of use: http://www.cadtutor.net/forum/showthread.php?91913-Delete-only-plot-configs-that-contain-specific-word-in-name... Cheers Quote
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.