Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.

Peter Cunliffe

PR and Windows Installer

This topic is 6589 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m trying Windows Installer 1.1 instead of InstallShield for my PR project. When I launch my project from a shortcut created by the installer my EXE can''t find it''s data files. If I switch to the program directory and click directly on the EXE it runs ok. I notice shortcuts created by Windows Installer are different from the normal ones and don''t have the "Start in:" directory option. If that is blank on a standard shortcut - same results. Anyone got a cure for this? Thanks in advance for helping! Petrovski

Share this post

Link to post
Share on other sites
You need to have the game directory put in the Start In: field of the shortcut. I don''t know how to do this with Windows Installer (Never used it). It happens because if Start In: isn''t set, the current working directory is whatever it was last set to, which could be anything, and if you reference any data as .\whatever, your referencing that current working directory which has not been set because Start In: is empty.

It works if you goto the directory and run the program because then you are running the executable not the shortcut and windows always sets the current working directory to that of the executable it is running.

I guess another thing you could do would be to store the location of the data information in the registery and have your program use that pathname for the data files. But it would be much easier just to have the installer set the Start In: directory.


Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!