PDA

View Full Version : Auto-Reload Linetypes without prompting



jrd.chapman
2004-07-28, 06:12 PM
Does anyone know of a way in Lisp to load ALL linetypes from a specified file, automatically Re-loading any linetypes that already exist in the drawing.

I'm trying to supress the prompt asking the user if they want to re-load a linetype that already exists in the drawing.

Any ideas?

Thanks in advance

John D. Chapman

sinc
2004-07-28, 07:08 PM
You're aware that you can use standard methods (shift-select, ctrl-select, ctrl-A, etc.) to select more than one linetype in the Load Linetype dialogue? If some are already loaded, Autocad then gives you a "Reload?" dialogue box with a "Yes to all" option, so you don't have to say "Yes" for each one.

RobertB
2004-07-28, 07:16 PM
(setvar "Expert" 3)
(command "._linetype" "_load" "*" "acad" "")
(setvar "Expert" 0)

Note that I recommend saving the current value of Expert, before setting it to 0, and then restoring the original value.

jrd.chapman
2004-07-28, 09:29 PM
Ah Ha! Thanks Robert, I never even thought of the Expert variable. Thanks very much. This will allow me to load all linetypes without ANY re-load dialog coming up...which is what I need.

Thanks again!

John D. Chapman