One of the most typical reasons is the protection of the file system.
People often use some illegal file path names. Strictly speaking, such applications are incorrect in first place, but XP is tolerant to such mistakes, but Windows 7 is strict.
You can of cause recommend the users to provide proper access rights for the directories you use, and everything will work, but this is not a solution. Basically, there are no situations where any hard-coded file path can be useful. You need to calculate those paths based on system configuration or application location. I provided full information in my past answers:
Entry assembly: How to find my programs directory
"special folders", working directories: How to find my programs directory