The directory name is invalid is an annoying issue which may happen to SD cards, USB flash drives, internal hard drives, as well as CD/DVD discs. When you are using CMD, this error can also happen. How to get rid of this issue effectively? This MiniTool post will tell you the answers.

Are You Disturbed by the Directory Name Is Invalid Issue?

The directory name is invalid is an annoying issue. When you are bothered by it, you will be unable to open certain files like Word or access the data storage devices including hard drives, SD cards, USB flash drives, and so forth.

Besides, this issue can also happen to OneDrive or network drive. Sometimes, when you open CMD.exe, this error pops out.

It seems that this error can happen anytime and anywhere. When you search for it on Google, you will discover that many people have encountered or still face this issue. Thus, it is quite necessary to summarize some full solutions to getting rid of this problem.

In the following parts, different situations and corresponding solutions are introduced. You can just choose one accordingly to help you out.

Situation 1: The Directory Name Is Invalid SD Card/External Hard Drive/USB Flash Drive

Indeed, the directory name is invalid issue often happens to SD cards, external hard drives and USB flash drives.

To solve the directory is invalid SD card/external hard drive/USB flash drive issue, you can try these solutions:

  • Use another USB port
  • Check disk errors
  • Update disk driver

Here, we take Windows 10 SD card error the directory name is invalid as an example. For external hard drive and USB flash drive, the solutions are similar.

Fixes for the Directory Name Is Invalid SD Card/External Hard Drive/USB Flash Drive

Fix 1: Use another USB Port

Usually, there is more than one USB port on the computer. Thus, you can try to connect the SD card via a card reader to the machine by using another USB port to see whether you can get rid of the directory name is invalid issue.

If Windows 10 SD card error the directory name is invalid error continues, please move on to the next fix.

If Your USB Port Not Working, These Solutions Are Available
If Your USB Port Not Working, These Solutions Are Available

USB port not working? No matter you are using Windows 10/8/7 or Mac, you can read this article to find a proper solution to fix this issue.

Read More

Fix 2: Check Disk Errors

If there are disk errors on the SD card, the directory name is invalid error can also occur. So why not check disk errors to have a try?

Here, you can use CHKDSK to check disk errors. To do this job, you need to follow these steps:

Step 1: Click on the Windows and R keys simultaneously to open the Run window. Then, you need to type cmd into the search box and press the Enter button.

Step 2: You will enter the cmd.exe interface. Next, you need to type in the appreciated command line. Suppose that the SD card drive letter is G. Then, you can type chkdsk g: /r /f into the interface and press the Enter button.

run CHKDSK

Step 3: Then, CHKDSK will begin to check and fix the found logical disk errors. When the process ends, you can go to see whether you can open the SD card successfully.

Fix 3: Update Disk Driver

When both of the above two fixes don’t work, you can consider updating USB driver software.

Step 1: Open the Run window, type devmgmt.msc into the search box and press OK to enter the Device Manager interface.

Step 2: Unfold the Universal Serial Bus Controllers section. Then, you need to right-click on the controller and choose the Update Driver Software option from the pop-out list. Then, you can follow the wizard to finish the update process.

update driver software

If the directory name is invalid issue persists, you can utilize this free file recovery tool - MiniTool Power Data Recovery to restore the data if they are important.

Recover Data with MiniTool after Fixing the Directory Name Is Invalid Issue

MiniTool Power Data Recovery is a dedicated data recovery program which can be used to retrieve files from multiple data storage devices including computer hard drives, SD cards, USB flash drives, and more.

To recover data from SD card, you can use the Removable Disk Drive module.

Want to know whether this software can recover your wanted files? Now, you can press the following button to download and install the Trial Edition of the software to have a try.

Free Download

To recover data from SD card, you can operate the software like this:

Step 1: Insert the SD card into the card reader and connect it to the computer. Then, open the software and you will enter This PC module directly. Next, switch to Removable disk drive module.

Tip: If you want to recover data from an internal hard disk, you need to use This PC module.

choose Removable Disk Drive module

The target SD card will be displayed on the software interface. Then, you need to choose it and click on the Scan button to begin the scanning process.

Step 2: It will take a while to finish the scanning process. When it ends, you will see the scan result.

enter scan result

You can open each path to find the data you want to recover. On the other hand, you can switch to the Type option to make the software show you the scanned files by type which can help you find the desired data easily.

Besides, if you still remember the name of the file, you can use the Find feature to locate the file directly.

Additionally, you are allowed to preview some types of file which are no larger than 20MB, like photos and text files.

Step 3: With the Trial Edition, you are not allowed to save the selected files. However, you can update this software to a full edition and then recover files to a specified location without limits.

trial edition limit

See! It is pretty simple to recover your SD card data with this MiniTool data recovery software.

Click to Tweet

Situation 2: The Directory Name Is Invalid Word

Some of you also encounter the directory name is invalid Word issue just like the following case:

I've created some medication lists in what I guess are .docx files. Now, when I try to open them, I get the message "directory name is not valid". How do I correct this?

To get rid of this error message, you can first change the document’s location and then try to open it again. If the directory name is invalid error still appeared, the Word document may be damaged. In this situation, you can refer to this Microsoft support post to fix the problem: How to troubleshoot damaged documents in Word.

If you want to recover your lost or deleted Word document, you can also use the MiniTool data recovery software.

How To Recover Unsaved Word Document - Ultimate Guide
How To Recover Unsaved Word Document - Ultimate Guide

Please don’t be bothered by how to recover unsaved Word document; there are wonderful solutions to solving it.

Read More

Situation 3: The Directory Name Is Invalid CD Drive

After a clean install or an update of Windows 10, many users report that when they insert a disc into the CD/DVD drive, the directory name is invalid error message appears. To solve the directory name is invalid CD drive problem, you can do these two attempts:

  • Re-enable the DVD drive
  • Uninstall the DVD drive

Fix 1: Re-enable the CD/DVD Drive

Step 1: Enter the Device Manager interface and unfold the DVD/CD-ROM drives section. Then, right-click on the drive and choose Disable from the popup list. When the confirm window appears, click on the Yes button to allow the change.

disable

Step 2: Then, choose the Enable option from the pop-out list after right-clicking on the DVD/CD-ROM drives section.

enable CD/DVD drive

Then, you can go to see whether the directory name is invalid CD drive error disappears. If this method doesn’t work, try fix 2 now.

Fix 2: Re-install the CD/DVD Drive

Step 1: Still, you need to unfold the DVD/CD-ROM drives section. Next, choose Uninstall from the popup list after right-clicking on the DVD/CD drive.

uninstall DVD/CD drive

Step 2: A confirm window shows. Please click on the OK button to confirm this operation.

Then, reboot the machine and the DVD/CD drive will be installed automatically. At last, you can insert the disc into the DVD drive to check whether you can use it as normal.

If this issue persists, you can use the CD/DVD Drive module of MiniTool Power Data Recovery to recover the important data on the disc.

Free Download

Situation 4: Diskpart the Directory Name Is Invalid

When you want to access CMD to solve some issues, you may receive the directory is invalid error. To handle Diskpart the directory name is invalid issue, you can do these operations:

Step 1: Type cmd into the search box. Then, choose Open file location from the list after right-clicking on Command Prompt.

open file location

Step 2: After entering the path, right-click on Command Prompt and choose Properties from the popup list.

Properities

Step 3: Under the Shortcut section, change the value in the Start in box from %HOMEDRIVE%%HOMEPATH% to %WINDIR%. Then, click on the Apply and OK buttons successively to save the change.

change Start in value

If there is no other issue, Diskpart the directory name is invalid issue should be solved successfully.

Click to Tweet

Situation 5: The Directory Name Is Invalid Network Drive Windows 10

Someone say that they see the directory name is invalid error when they want to access files on the mapped network drive. There are two solutions as follows:

Fix 1: Disable UAC

Usually, the directory name is invalid network drive Windows 10 issue always happens if the User Access Control (UAC) is enabled. Thus, you can disable it to have a try.

Step 1: On Windows 10, type UAC into the search box on the low-left side of the desktop. Then, choose Changing User Account Control settings from the search result.

Step 2: In the User Account Control Settings interface, you need to move the slider down to the Never notify location. After that, press the OK button to keep the change.

disable UAC

Fix 2: Create a System Temp Folder

If there is no a system temp folder in C drive, the directory name is invalid network drive Windows 10 can also happen.

Thus, go to the C drive to have a look. If there is no such a folder (the path is always like this C:\Windows\Temp), create one and then go to try whether you can open files from the mapped network drive normally.

Situation 6: OneDrive the Directory Name Is Invalid

OneDrive the directory name is invalid is another similar issue. Indeed, the reasons for this issue are various including invalid characters, invalid file or folder names, invalid or blocked file types, etc.

Microsoft has some full solutions about OneDrive the directory name is invalid issue and you can get them from this official post: Invalid file names and file types in OneDrive, OneDrive for Business, and SharePoint.

Situation 7: iPod the Directory Name Is Invalid

The minority reflect that the directory name is invalid issue happens to iPod. Here is a real-life example from answers.microsoft.com:

I am having an issue with plugging in my iPod and receiving this message: G:\ directory name invalid. iTunes doesn't recognize my iPod either.

Actually, there is no need to worry about this issue. The easiest way is to reboot the iPod to have a try. If iPod the directory name is invalid problem still occurs, you can reinstall the USB drivers on the computer and restart the system to check if that helps.

Detailed Steps to Reinstall USB Drivers

Step 1: Enter the Device Manager interface and then expand the Universal Serial Bus controllers section.

Step 2: Right-click on the Universal Serial Bus controllers’ node, and choose Uninstall. If there is more than one USB controller, repeat this step to uninstall them all.

uninstall USB driver controllers

Step 3: Reboot the computer and then the machine will reinstall the USB controllers automatically.

Once all the USB Controllers are installed, connect the iPod again to see whether the error disappears.

Solved Perfectly - How to Recover Deleted Videos from iPhone
Solved Perfectly - How to Recover Deleted Videos from iPhone

How to recover deleted videos from iPhone? This free iPhone data recovery software - MiniTool Mobile Recovery for iOS can solve this issue effectively.

Read More

Bottom Line

7 different situations about the directory name is invalid issue, as well as the corresponding solutions are introduced in this post. You can choose one depending on your actual condition.

If you encounter some problems when you are using MiniTool software to handle this problem, you can let us know in the comment or send an email to [email protected]. You can also share your ideas and solutions with us. Thank you!

The Directory Name Is Invalid FAQ

How do I fix the directory name is invalid?
When you encounter the Directory name is invalid issue when using the data storage drive, you can first try another USB port to see whether the issue can be solved. You can also use CHKDSK to check and fix the errors on the drive or update the driver for the drive.
What is a directory name?
A directory name is a string that must name a directory if it names any file at all. A directory is actually a kind of file, and it has a file name (called the directory file name, which is related to the directory name but is typically not identical).
How do you fix the file or directory is corrupted and unreadable?
  1. Use CHKDSK to fix error on the drive.
  2. Format the drive to its normal state.
  3. Check whether there are bad sectors on the drive.
How do I fix the incorrect parameter on my external hard drive?
  1. Format the external hard drive to its normal state.
  2. Use CHKDSK to fix errors and shield bad sectors on the drive.
  • Linkedin
  • Reddit