How can I tell if a command is available in real DOS?
15:22 03 Jun 2026

I want to create a batch program that allows me to execute a command, but only if the command is available in MS-DOS 6.22.

The command is accessible as long as it is located in any path included in the PATH.

Example:

SET COMMAND=STRINGS.COM
IF NOT EXIST %COMMAND% GOTO END
%COMMAND%
:END

The "EXIST" command doesn't work as in my example, so I need help finding a way to make it work.

Thanks in advance.

batch-file dos