views:

25

answers:

2

I've got an application that has a bug right now, but we're unable to update the end-user to get the fix out. What a possible workaround would be is to change the working directory to the application's install directory, but from what I can tell, there's no way to do that outside of the program itself. Is there some sort of Windows API call that can change other processes' working directories, or is that not available due to security issues? I figure it's not possible.

A: 

You can change the directory that it initially starts in with a shortcut. If that is not enough, I don't believe what you want is possible without injecting a custom dll into the process after the fact.

Joel Lucsy
A: 

Why do you want to change the working directory? Maybe you could modify the PATH environment variable in some way to change the order of directories your app searches for files.

Heinrich Ulbricht