Internal external commands windows

How-to: Internal commands

The Windows CMD shell CMD.exe contains a number of ‘internal’ commands, additional ‘external’ commands are also supplied as separate executable files. External commands are generally stored in the C:\WINDOWS\System32 folder, this folder is part of the system PATH .

This arrangement means that both internal and external commands are always available no matter what your current directory happens to be.

In the main A-Z list of CMD commands the internal commands are indicated with a •

When you are working from any other shell, such as PowerShell then none of the internal commands are available unless you first open a CMD shell.

Passing arguments

Arguments can be passed to an internal command, just like an external command, e.g. COPY /Y
In some cases (when the command is being parsed by CMD.exe) the space before each argument can be omitted e.g. COPY/Y this can save time when working at the command line, but for scripts and scheduled tasks it is better to include the space.

for example from PowerShell:

PS C: > cmd /c date /t

will launch a CMD shell, run the DATE /T command and then exit back to PowerShell. Of course in many cases this is not neccessary, (PowerShell has its own Date command) but can be useful if you need to run something ‘the old way’.

It is possible for a system to have an internal command and an external command with the same name. If you have a command called DATE.exe and want to run that in preference to the internal DATE command, use the full pathname to the file e.g. C:\utils\date.exe even if your current directory is C:\utils\

“Tongues, like governments, have a natural tendency to degeneration; we have long preserved our constitution, let us make some struggles for our language” — Samuel Johnson: Preface to the Dictionary

Fix “Not Recognized As an Internal or External Command” Win 10 [MiniTool News]

By Alisa | Follow | Last Updated December 31, 2020

Summary :

If a command is not recognized as an internal or external command, it may be due to the messed up environment variables. Check how to fix this error in this post. To help you tackle data loss, manage hard drive partitions, backup and restore system, MiniTool software provides professional tools.

If you meet the error “command is not recognized as an internal or external command, operable program or batch file” problem in Command Prompt in Windows 10, the reason may be that the Windows Environment Variables are messed up. Check what Windows Environment Variables are and how to fix this error below.

Check how to change directory in CMD (Command Prompt) by using CD command in Windows 10. Detailed Command Prompt change directory guide.

Windows Environment Variables

Windows OS has a list of path to record the locations of most common system applications. When you use the Run prompt or CMD.exe to open a program, it can launch easily. This list is called Windows Environment Variables.

Your operating system uses the PATH system variable to locate needed executables from the Command Prompt or Terminal application.

If the Windows Environment Variables are messed up, it may cause some programs not working like Command Prompt not working.

Читайте также:  Как установить касперский для windows 10

You can learn how to fix not recognized as an internal or external command error in Windows 10 when you try to execute a command or open a system program in Command Prompt.

Learn how to create and delete a file or folder with cmd. Use Windows Command Prompt to create and delete files and directories.

How to Fix Not Recognized As an Internal or External Command

Step 1. Go to C:\Windows\System32\ to check if the program actually exists. You can search and find the target exe file in System32 folder. If the program exists, then you can continue to modify the Windows Environment Variables to fix Command Prompt not recognizing commands errors.

Step 2. You can right-click This PC icon and select Properties. Click Advanced system settings to open System Properties window. After that, click Advanced tab and click Environment Variables.

Step 3. Then you can click Path under System variables, and click Edit button. Before you edit the PATH system variable, it’s advised you copy and paste the old environment variables to a text file to make a backup. In case something goes wrong, you can easily revert them.

Step 4. Check if there is a directory path of the executable file location, if not, enter the location of the executable file’s parent folder. After you edit the value, you can click OK.

Step 5. Then you can reboot your computer and execute the command again to see if the “not recognized as an internal or external command” problem is fixed in your Windows 10 computer.

Wonder how to clear Command Prompt (CMD) screen in Windows 10? Use CLS command or some other ways to clear CMD history.

How to Recover Deleted/Lost EXE Files in Windows 10

If some exe files are automatically or mistakenly deleted or unexpectedly lost in your Windows 10 computer, you can use MiniTool Power Data Recovery to easily recover exe files.

MiniTool Power Data Recovery is a professional easy-to-use data recovery program for Windows 10. You can use it to recover any deleted/lost files (incl. application exe files) from Windows 10 computer with ease. Still, this best data recovery software also allows you to recover deleted/lost files from external hard drive, USB flash drive, pen drive, thumb drive, SD card, and more. The free edition allows you to recover up to 1GB data totally for free. 100% clean and safe software, and extremely intuitive interface.

Easy 3 steps to fast recover my files/data for free with best free file recovery software. 23 FAQs for how to recover my files and lost data are included.

  • Facebook
  • Twitter
  • Linkedin
  • Reddit

ABOUT THE AUTHOR

Position: Columnist

Alisa is a professional English editor with 4-year experience. She loves writing and focuses on sharing detailed solutions and thoughts for computer problems, data recovery & backup, digital gadgets, tech news, etc. Through her articles, users can always easily get related problems solved and find what they want. In spare time, she likes basketball, badminton, tennis, cycling, running, and singing. She is very funny and energetic in life, and always brings friends lots of laughs.

How to Fix “not recognized as an internal or external command” in Windows

Due to messed up environmental variables

One of the great things about Windows is that you can get many of your tasks done from the Command Prompt on your machine. You just need to enter cmd.exe and Windows will run it for you. But occasionally, you might come across errors like “is not recognized as an internal command”.

This is actually one of the most common errors you can face with the Command Prompt. As the error itself suggests, it couldn’t recognize the tool you were trying to use with the Command Prompt. There are various reasons why it happens, and also there are multiple ways to get around the “not recognized as an internal or external command” error on your Windows PC.

Читайте также:  Linux установить права файл

Why The “not recognized as an internal command” Error Occurs

Before you start applying fixes, it’s a good idea to learn why the error occurred so you can ensure it doesn’t happen again in the future.

Other Apps Messing Up Your System

One of the most common reasons you may get this error on your PC is because another installed app modified your system variables. This prevents the Command Prompt from recognizing commands to launch other apps or tools.

Not Having The Program Installed On Your Computer

The second possible reason the “not recognized as an internal or external command” occurs is that you don’t have the appropriate program installed on your computer. It may be that the installer didn’t install the application files at the appropriate location, or the installer didn’t enable the tool to be launched with Command Prompt.

Fixing The “not recognized as an internal or external command” Error In Windows

Regardless of the cause, there are ways to fix this error and get the Command Prompt to recognize the program that you’re trying to use.

Ensure The Program Actually Exists On Your PC

The first thing to do is verify if the program that you’re trying to use with the Command Prompt actually exists on your computer. You may have used a fake installer that told you that the program was successfully installed on your machine, but that may not be true.

There’s an easy way to check if the program is indeed installed on your machine.

  • Launch a File Explorer window on your PC.
  • Head over to the following path.

C:\Windows\System32\

  • Ensure the executable that you’re trying to run from the Command Prompt is available in this folder. If it’s not, the program is likely not installed on your computer.

The above isn’t a surefire way to check if a program is installed on your computer. This is because not all programs keep their files in the Windows’ System32 folder. However, it should help you locate most programs.

Use The Full Path To The Executable File

The “is not recognized as an internal command” error usually occurs because the computer can’t find the executable that you’re asking it to launch. However, you can provide it with the full path to your executable file and it should then be able to run it without any issues.

  • Launch a Command Prompt window on your PC.

  • Type in the full path of the executable that you want to use and hit Enter on your keyboard.
  • For example, if you’re trying to use adb.exe that’s located in a folder called adb on your desktop, you’ll type something like the following.

C:\Users\ \Desktop\adb\adb.exe

  • The file should launch without an issue.

Enclose The File Path With Double Quotes

Specifying the full path to your executable file isn’t a bulletproof method. It can also cause the “is not recognized as an internal or external command” error if it isn’t used properly. The problem lies in the path that you specify in your Command Prompt window.

If your executable file’s full path has any spaces in it, that’s going to cause the error. This is because the utility can’t recognize the spaces, and it uses the characters up to the first space as a program name. Since that isn’t the correct path, you’ll get the aforementioned error.

You can fix this using the following method.

  • While typing in a path that has spaces (whether single or multiple), enclose the path with double quotes.

  • Command Prompt will then recognize the entire path as a single item and launch the program appropriately on your machine.

Move The File To System32 Folder

By now, you know that when you try to run an executable from the Command Prompt utility, it looks into the System32 folder of your Windows installation and then opens the file, if it’s available there.

What if you could place your executable file there and then access it from the Command Prompt? You can do this as long as you have admin access on your computer.

    Copy the executable file along with all other files associated with it to the following folder on your computer.

C:\Windows\System32

  • Close Command Prompt if it was already open and relaunch it.
    • Enter the name of your executable file without any path, and you’ll find it launches successfully.

    While this method works great and helps you fix the “is not recognized as an internal or external command” error on your computer, you may want to use it cautiously.

    This is because each time you want to use something from the Command Prompt, you’ll need to put the appropriate executable in the System32 folder. Eventually, the folder will grow large and you’ll have a large number of files sitting in there.

    It also won’t work for executable tools that require installation into a specific directory. You won’t be able to move those into the System32 folder since the installation path is defined in the Windows Registry.

    We recommend you only use this solution if you can’t fix the issue using the other methods and as long as the application doesn’t require installation.

    Add The Executable File Path To Environment Variables

    The most efficient way to fix the “is not recognized as an internal command” error is to edit your environment variable and add the appropriate file path there. This is because the Command Prompt utility looks at those paths when you enter a command, and then opens the file if it finds it in one of those directories.

    By adding your file path there, you’re telling Command Prompt where a certain executable is located when you want to use it by its short-name in a CMD window.

    It’s pretty easy to edit your variables and add a new path there.

    • Launch Control Panel using the Cortana search on your PC.

    • Click on the option that says System and Security.

    • Find and click on System on the following screen.

    • Select Advanced system settings from the left sidebar on your screen.

    • A box will open on your screen. Click on the Environment Variables button which is located at the bottom of the box.

    • You’ll see all the user variables for your account. Click on the one that says Path and then click on the Edit button.

    • You can now add the new path to the application you want to use with the Command Prompt. Click on Browse in the right sidebar to add a directory to the list.

    • Navigate to the folder where your executable is located and select it.
    • You should see your newly added path is listed in the variables list. Click on OK at the bottom to save the changes.

    • Click on OK in all other boxes as you close them.
    • Open a Command Prompt window and type the name of the executable file. You’ll see that the file opens without CMD throwing any errors on your screen.

    The “is not recognized as an internal command” error can sometimes be very frustrating, as it won’t let you use a program that you know you’ve installed on your computer.

    Using the methods above, you should be able to get rid of this error and run any program from a Command Prompt window without any issues. If any of the methods above helped you fix the issue, we’d like to know about it in the comments section below.

    Mahesh has been obsessed with technology since he got his first gadget a decade or so ago. Over the last few years, he’s written a number of tech articles on various online publications including but not limited to MakeTechEasier and Android AppStorm. Read Mahesh’s Full Bio

    Читайте также:  Acer ноутбук не видит загрузочную флешку windows 10
    Оцените статью