Windows Vista missing files written to “Program Files” folder?
25 February 2007While working on WWWinamp, I ran into an issue that had me baffled for a few hours. I’m writing this blog entry as an attempt to reach out to those who may have a deeper understanding of what is happening as well as trying to give my two cents for those looking for an answer.
WinAmp has an IPC titled IPC_WRITEPLAYLIST which writes the currently in-use playlist to “winamp.m3u” and places it into the folder WinAmp is currently installed in (which is traditionally C:\Program Files\WinAmp\). Well, starting with WinAmp 5.33, WinAmp seemed to no longer save the file to this location (only) under Windows Vista.
I had also noticed starting with WinAmp 5.32, after upgrading to Windows Vista, that the Media Library would no longer be saved after it had been scanned/created.
Well, after a few hours of pulling out my hair trying to understand why everything worked fine on my file server running Windows XP, yet nothing seemed to work under Vista, I discovered that Windows Vista by default does not allow writing to the “Program Files” folder by default.
Any files that may be written to this directory by an application running from within seems to be redirected to “C:\Users\(USER NAME)\AppData\Roaming\”.
This means you may run into some application compatibility issues when running Windows Vista due to files being saved now to a different physical location.
I can understand why this was done, and it makes sense. If I am logged in and I generate my media library, any other user who logs into the computer and starts WinAmp under their user name will not be able to see the Media Library that was generated and saved under my user name.
It also just creates another issue for developers, because now I’m forced to detect the OS version in my application before reading information which may have been generated to the “Program Files” folder.
No comments yet