Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

VerFindFileVersion


4 replies to this topic

sakbuddika

sakbuddika
  • Members
  • 8 posts

Posted 24 May 2002 - 13:35

I am using InstallShield 6.3
But when I use VerFindFileVersion() it doesn't look for PATH
Please help.

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 25 May 2002 - 01:41

Ahh, well in that case you'll probably have to look up the current value of the PATH, separate it out based on the semicolons to get a list of possibilities (i.e. Path1; Path2 => Path1 & Path2), and trying calling the function with each one of them (i.e. VerFindFileVersion(szFilename, "Path1", svVesion), etc.).

The PATH information is stored in the following registry entry:
HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment\Path
user posted image

hteichert

hteichert
  • Members
  • 158 posts

Posted 27 May 2002 - 21:55

Sorry, TacoBell00, but you can find the environment only for Win NT, Win 2K and XP at the given place in the registry.
It doesn't work (for sure!) on win 95. I can't check it now, but I believe that it doesn't work on 98 or ME, too.
h.teichert-ott

Taco Bell

Taco Bell

    IS6 Expert

  • Moderators
  • 1,281 posts

Posted 28 May 2002 - 03:33

Ooh yeah.  Sometimes I forget about those Win9x targets since I don't write installs for them.  Sorry.

There should be some equivalent location in Win9x/Me though.
user posted image

hteichert

hteichert
  • Members
  • 158 posts

Posted 28 May 2002 - 11:35

I just had a look around and it's much trickier with this "path":
On NT/W2K/XP there are two places where environment variables are defined in the registry.
One for everybody:
"HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment\Path"
And one for every single user:
"HKCU\Environment\Path"
The one for the current user is added at the of the one for everybody when running a DOS-box for example.

On 95 there is no path entry in the registry. On ME there is an entry in:
"HKLM\SYSTEM\CurrentControlSet\Control\SessionManager\Environment\Path"
Attention!
Here is the space in "SessionManager" missing compared to NT/W2K/XP.
On 98 I couldn't look, no system running currently.

Because of all these differences I think it's best to run a batch which outputs the "Path" environment variable to a textfile and read this textfile to get the real path variable content (simply one line: "path > pathfile.txt").
h.teichert-ott