#1
|
|||
|
|||
Environment Variables
With the integration kit function sd-sys-getenv one can inquire the environment variable values from the OS.
Is there a way (from LISP inside of Modeling) to actually create or set new environment variables? You can do these things from Drafting using GETENV and PUTENV (the latter being one of those "undocumented" keywords). I thought there might be equivalents in Modeling but so far I haven't figured out how to create/set environment variables there. Thanks for any assistance, |
#2
|
||||
|
||||
Re: Environment Variables
You could use SD-SYS-EXEC to run either a set or setx command.
Code:
(sd-sys-exec command) Description: Forks an operating system shell and executes command in that shell. Returns the operating system return value of the command. Note: If you want to pass a filename (pathname) as argument to this function you have to convert the filename to the platform specific notation using the function sd-convert-filename-to-platform. Parameters: command {STRING} - the operating system command to execute Return value: return-code {FIXNUM} the value returned by the command to the OS shell |
#3
|
|||
|
|||
Re: Environment Variables
That suggestion works, but not for the currently running session of Modeling. http://technet.microsoft.com/en-us/library/cc755104(WS.10).aspx
I was looking for a way to set an environment variable that the current session could later inquire and act upon. |
#4
|
||||
|
||||
Re: Environment Variables
I think (putenv "myvar" "1") should work
__________________
High performance CAD workstations Please visit us at https://www.cadware.nl |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|