ILoveMadoka Posted December 23, 2009 Posted December 23, 2009 This is a followup to this thread.. http://www.cadtutor.net/forum/showthread.php?t=43123 Is there a SETVAR for the Toggle to Display Lineweight? I have something that toggles it ON from time to time and would like to just set it to be OFF when Autocad starts. In my startup preferrably. TIA!! Quote
ReMark Posted December 23, 2009 Posted December 23, 2009 Perhaps this? "The default value is set by the LWDEFAULT system variable, which has an initial value of 0.01 inches or 0.25 mm. All new layers use the default setting. The lineweight value of 0 plots at the thinnest lineweight available on the specified plotting device and is displayed at one pixel wide in model space." Quote
ILoveMadoka Posted December 23, 2009 Author Posted December 23, 2009 LWDisplay!! You're my hero!! On a side note how would I write a routine to go through all layers in a drawing and set the lineweight to Default for each layer? Drawings imported from Solidworks sometimes set a lineweight for different layers... Quote
Lee Mac Posted December 23, 2009 Posted December 23, 2009 Try this: (defun c:lwd nil (vl-load-com) (vlax-for lay (vla-get-Layers (vla-get-ActiveDocument (vlax-get-acad-object))) (vla-put-lineweight lay acLnWtByLwDefault)) (princ)) Or (defun c:lwd (/ tdef) (while (setq tdef (tblnext "LAYER" (not tdef))) (entmod (subst (cons 370 -3) (assoc 370 tdef) tdef))) (princ)) Quote
wizman Posted December 23, 2009 Posted December 23, 2009 LWDisplay!! You're my hero!! On a side note how would I write a routine to go through all layers in a drawing and set the lineweight to Default for each layer? Drawings imported from Solidworks sometimes set a lineweight for different layers... Merry Christmas Everyone! Quote
ILoveMadoka Posted December 23, 2009 Author Posted December 23, 2009 Lee... Once again... YOU ARE THE MAN!! When I grow up I want to program just like you!! Thank you and MERRY CHRISTMAS!! 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.