Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Evironment Variables
#3
Special folders and environment variables are not automatically expanded in run's second argument. Use str function expandpath.

hosts :run "notepad.exe" _s.expandpath("$windows$\system32\drivers\etc\hosts")

or

hosts :run "notepad.exe" _s.expandpath("%windir%\system32\drivers\etc\hosts")

_s is str variable that does not need to be declared.


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)