AhmadAssaf
AhmadAssaf

Reputation: 3664

Dealing with ini Files - Add Enivornment Variable

i am trying to add an evironment variable to a path inside an ini file, the variable is the current username in Windows which can be accessed via %username%.

so i would like to do path = c:\users\[username variable]\ ...

Will appreciate anyhelp

Upvotes: 0

Views: 1620

Answers (2)

Hans Passant
Hans Passant

Reputation: 941655

Use ExpandEnvironmentStrings().

Upvotes: 1

Sam Axe
Sam Axe

Reputation: 33738

See WritePrivateProfileString() and friends...

Upvotes: 0

Related Questions