Fix ERROR_BAD_CURRENT_DIRECTORY (0X000002BF) on Windows
This error pops up when a program can't access its startup folder. Usually after moving or copying a program's files or shortcuts.
When This Error Shows Up
You're trying to launch a program — maybe a game you downloaded, a business app, or some old utility. Instead of starting normally, you get this message:
ERROR_BAD_CURRENT_DIRECTORY (0X000002BF)
{Invalid Current Directory} The process cannot switch to the startup current directory %hs
I see this most often when someone moves a program's folder after installing it. For example, you install a game to C:\Users\YourName\Downloads\Game, then later copy the whole folder to D:\Games\. The shortcut in your Start Menu still points to the old location, and the executable can't find its own startup directory. Another common trigger: you copy a portable app from one PC to a USB drive, then run it from a different drive letter on another machine.
What's the Root Cause?
Every Windows process gets something called a "current directory" when it starts. Think of it as the program's home base — where it looks for its config files, assets, and support DLLs. When you launch a program, Windows sets this current directory based on the shortcut's "Start in" field or the executable's own location.
The error 0x000002BF means Windows tried to set that directory, but the directory no longer exists. It's like telling someone "go to your desk" but the desk has been moved to another room. The program can't find its own stuff, so it crashes out with this error.
The key thing to understand: it's not the program itself that's broken. It's the path that leads to it. The shortcut or the registry entry has an old, stale location.
How to Fix It
Step 1: Check the Shortcut's 'Start in' Field
Right-click the shortcut that gives you the error. Pick Properties from the menu.
In the Shortcut tab, look for the Start in box (also labeled as "Working directory" on some systems). This is the folder Windows tries to switch to when the program starts.
You'll probably see a path there that doesn't exist anymore — like C:\Users\OldUser\AppData\Roaming\SomeApp or a drive letter you no longer have.
Change it to the folder where the program's EXE actually lives. If the EXE is in D:\Games\MyGame\, set the Start in field to D:\Games\MyGame\.
Click Apply, then OK.
Try running the program again. If it works, you're done — the fix was that simple.
Step 2: Delete the 'Start in' Field Entirely
Sometimes the Start in field is set to something weird — like a network path that's no longer mapped, or a folder you deleted ages ago. If Step 1 didn't fix it, clear that box completely.
Leave it blank. Windows will then use the EXE's own folder as the current directory. For most programs, that's exactly what they want.
Click Apply and OK.
Test the program again.
Step 3: Recreate the Shortcut from Scratch
If the Start in field was already blank or you cleared it and the error persists, the shortcut itself might be corrupted. Here's how to build a fresh one:
- Right-click an empty spot on your desktop or in a folder. Pick New > Shortcut.
- Click Browse and navigate to the program's EXE file. Select it, then click OK.
- Click Next. Give the shortcut a name — anything you'll recognize.
- Click Finish.
Now try launching the program using this new shortcut. If it works, delete the old broken one and use this one instead.
Step 4: Run the Program Directly from Its Folder
Open File Explorer and go to the program's actual folder. Double-click the EXE file right there. Does it run without the error?
If yes, the problem is definitely in the shortcut's path. Go back to Step 1 and make sure the Start in field matches the folder you just opened.
If the program still gives the same error even when run directly from its folder, the issue is deeper — maybe the folder itself is corrupted or the program is looking for a subfolder or file that's missing. In that case, reinstall the program from scratch. Delete the whole folder first, then run the installer again.
What If It Still Fails?
Sometimes this error comes from a scheduled task or a service — not a regular desktop shortcut. Check the Task Scheduler (hit Windows+R, type taskschd.msc, press Enter). Find the task that runs the program, open its properties, and look at the Actions tab. The Start in field there might have the wrong path.
For services, open Services.msc, double-click the service, go to the Log On tab, and make sure the This account path is correct. But honestly, 9 out of 10 times this error is just a bad shortcut Start in field. Focus on that first.
Was this solution helpful?