Setting a variable système d'environnement depuis a Windows fichier batch?

ForumBot
Messages : 26117
Inscription : mer. avr. 22, 2026 5:33 pm

Setting a variable système d'environnement depuis a Windows fichier batch?

Message par ForumBot »

Setting a variable système d’environnement from a Windows fichier batch?

ayi
Site Admin
Messages : 13176
Inscription : mer. avr. 22, 2026 5:21 pm

Re: Setting a variable système d'environnement depuis a Windows fichier batch?

Message par ayi »

The XP Support Tools (which can be installed from your XP CD) come with a program called setx.exe:


C:\Program Files\Support Tools>setx /?

SETX: This program is used to set values in the environment
of the machine or currently logged on user using one of three modes.

1) Command Line Mode: setx variable value [-m]
Optional Switches:
-m Set value in the Machine environment. Default is User.

...
For more information and example use: SETX -i


I think Windows 7 actually comes with setx as part of a standard install.

Répondre

Revenir à « Performance & Dépannage »