Bernd,
In the Preferences objects, there are many properties that refer to environment variables maintained by AutoCAD.
If you mean system environment variables, I can only think of API calls such as SetEnvironmentVariable. It's not a simple task and I'd recommend a search on the net (including the word "VBA" to sift out any references for C etc.)