Jump to content

Recommended Posts

Posted

Does any way exist to find out all settings in Files Tab of Options via AutoLISP, then change them to desired values?

Posted
Does any way exist to find out all settings in Files Tab of Options via AutoLISP, then change them to desired values?

 

Getenv

Setenv

 

or

 

(vla-get-files (vla-get-preferences (vlax-get-acad-object)))

 

See attached:

 

AutoCAD Environment Variable Quick Guide.pdf

Posted

pBe,

thank you for your reply.

 

Getenv

Setenv

I don't know how to use getenv and setenv, i.e. I have no knowledge about the name of the variables.

 

(vla-get-files (vla-get-preferences (vlax-get-acad-object)))

The code is very good to get environment variables, so thank you for the help, but how to set variables?

Guest kruuger
Posted

few sample:

(setq *files*
 (vla-get-files
   (vla-get-preferences (vlax-get-acad-object))
 )
)

(vla-get-TempDirectory *files*)
(vla-put-TempDirectory *files* "C:\\Temp\\")

(vla-get-PrinterConfigPath *files*)
(vla-put-PrinterConfigPath *files* "\\\\ahi\\support\\CAD_Install\\LD6\ahi\\PLOTTERS")

ok ?

kruuger

Posted

updated the post, attached pdf for SETENV/GETENV rererence for you

 

as for vl

 

IAcadPreferencesFiles: This object contains the options from the Files tab on the Options dialog

Property values:

AltFontFile =

AltTabletMenuFile =

Application (RO) = #

AutoSavePath =

ColorBookPath =

ConfigFile (RO) =

CustomDictionary =

CustomIconPath =

DefaultInternetURL =

DriversPath =

EnterpriseMenuFile =

FontFileMap =

HelpFilePath =

LogFilePath =

MainDictionary =

MenuFile =

PageSetupOverridesTemplateFile =

PlotLogFilePath =

PostScriptPrologFile =

PrinterConfigPath =

PrinterDescPath =

PrinterStyleSheetPath =

PrintFile =

PrintSpoolerPath =

PrintSpoolExecutable =

QNewTemplateFile =

SupportPath =

TempFilePath =

TemplateDwgPath =

TempXrefPath =

TextEditor =

TextureMapPath =

ToolPalettePath =

WorkspacePath =

Methods supported:

GetProjectFilePath (1)

SetProjectFilePath (2)

 

(vla-put-QNewTemplateFile VarName "NewValue")

where VarName is product of

 

(setq VarName (vla-get-files (vla-get-preferences (vlax-get-acad-object))))

 

to check if an object has a specified property

 

(vlax-property-available-p VarName 'DriversPath)

 

or

(setenv QnewTemplate "NewValue")

 

Setenv variable name is case sensitive so be careful with that

 

Hope this helps

Posted

pBe and Kruuger,

thanks for your help.

Posted
Kruuger, thank you for your aim, but in my country the address is FILTERED:shock::cry::bloodshot::reallymad:.

 

That sucks.

Posted

Just a suggestion when setting your paths you may want to use strcat and read existing paths and add your own then update paths this way you dont stuff up the generic Autocad ones.

 

Every body like me about to load 2012 this will help setups as we 13 to do.

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...