Jump to content



Photo

updating the path


  • Please log in to reply
No replies to this topic

#1 emmanuel

emmanuel

    No one ever accused me of being normal.

  • Active Members
  • PipPipPipPipPipPip
  • 1,128 posts

Posted 10 June 2004 - 01:29 AM

I have this program that is a completely manual install. so I'm sitting here half an hour after I should have left work writing a install for it... I have to check the path and make sure these three items are there... this could be made a UDF, and I'm sure I will, once I get around to it... for now, if you want to do it, you can...

;checking the path $_path = EnvGet("PATH") if StringInStr($_path, "%FORTE_ROOT%\install\bin") = 0 Then $newpath = $_path & ";%FORTE_ROOT%\install\bin" if StringInStr($_path, "%FORTE_ROOT%\userlib") = 0 Then $newpath = $_path & ";%FORTE_ROOT%\userlib" if StringInStr($_path, "C:\Program Files\Caminus\Common") = 0 Then $newpath = $_path & ";C:\Program Files\Caminus\Common" RegWrite("HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment", "PATH", "REG_SZ", $newpath) EnvUpdate()

Edited by emmanuel, 10 June 2004 - 01:37 AM.

"I'm not even supposed to be here today!" -Dante (Hicks)










0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users