cmd.exe/WinXP: identify internal commands

G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

I am looking for a way/method to display all internal commands which
are available on the command-line (CMD.EXE under WinXP). By that I mean
commands like "cd", "set", "dir", etc... which are not external *.bat
or *.exe files.

when I type "help" from the command prompt C:\>, that gives me (amongst
other information) a list of many commands (some are internal, such as
"DIR", some are external, such as "SORT", i.e. "SORT.EXE"), but I have
no way of knowing whether this list of commands is exhaustive or not.

Any other suggestions how to identify all internal commands ?
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

Command-line reference
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/ntcmds_o.mspx

Or >>

Command-line reference

Start | Run | Copy and paste the following line:

hh ntcmds.chm

Click OK.
-----

Command-line reference A-Z
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/ntcmds_o.mspx

Or >>

Command-line reference A-Z

Start | Run | Copy and paste the following line:

%windir%\hh.exe ms-its:c:\Windows\Help\ntcmds.chm::/ntcmds.htm

Click OK.

I have a shortcut to
%windir%\hh.exe ms-its:c:\Windows\Help\ntcmds.chm::/ntcmds.htm
on my Start Menu.
-----

New ways to do familiar tasks
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/dos_diffs.mspx

Or >>

New ways to do familiar tasks

Start | Run | Copy and paste the following line:

%windir%\hh.exe ms-its:C:\WINDOWS\Help\ntcmds.chm::/dos_diffs.htm

Click OK.

Scroll down to Unavailable MS-DOS Commands
-----

HOW TO: Set the Command Processor Appearance in Windows XP
http://support.microsoft.com/default.aspx?scid=kb;en-us;309019

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In news:1118859411.416920.208490@o13g2000cwo.googlegroups.com,
gov <gov300z@yahoo.com> hunted and pecked:
> I am looking for a way/method to display all internal commands which
> are available on the command-line (CMD.EXE under WinXP). By that I mean
> commands like "cd", "set", "dir", etc... which are not external *.bat
> or *.exe files.
>
> when I type "help" from the command prompt C:\>, that gives me (amongst
> other information) a list of many commands (some are internal, such as
> "DIR", some are external, such as "SORT", i.e. "SORT.EXE"), but I have
> no way of knowing whether this list of commands is exhaustive or not.
>
> Any other suggestions how to identify all internal commands ?
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

Apart from Wesley's expert advice, you can also type 'help' at the command prompt and press enter.
It shows a list of commands that are available under the command prompt.

--

Anando
Microsoft MVP- Windows Shell/User
http://www.microsoft.com/mvp
http://www.mvps.org

In memory of Alex Nichol
http://www.microsoft.com/windowsxp/expertzone/meetexperts/nichol.mspx

Folder customizations
http://newdelhi.sancharnet.in/minku

Protect your PC!
http://www.microsoft.com/protect


"gov" <gov300z@yahoo.com> wrote in message
news:1118859411.416920.208490@o13g2000cwo.googlegroups.com...
>I am looking for a way/method to display all internal commands which
> are available on the command-line (CMD.EXE under WinXP). By that I mean
> commands like "cd", "set", "dir", etc... which are not external *.bat
> or *.exe files.
>
> when I type "help" from the command prompt C:\>, that gives me (amongst
> other information) a list of many commands (some are internal, such as
> "DIR", some are external, such as "SORT", i.e. "SORT.EXE"), but I have
> no way of knowing whether this list of commands is exhaustive or not.
>
> Any other suggestions how to identify all internal commands ?
>
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

On 15 Jun 2005 11:16:51 -0700, "gov" <gov300z@yahoo.com> wrote:

>I am looking for a way/method to display all internal commands which
>are available on the command-line (CMD.EXE under WinXP). By that I mean
>commands like "cd", "set", "dir", etc... which are not external *.bat
>or *.exe files.
>
>when I type "help" from the command prompt C:\>, that gives me (amongst
>other information) a list of many commands (some are internal, such as
>"DIR", some are external, such as "SORT", i.e. "SORT.EXE"), but I have
>no way of knowing whether this list of commands is exhaustive or not.
>
>Any other suggestions how to identify all internal commands ?

The only method I know is by process of eliminations. Go to "Command
Line Reference A-Z" in help, <%systemroot%\hh.exe
Ms-its:%systemroot%\help\ntcmds.chm::/ntcmds.htm> then print the
list and cross of anything for which an external program exists.

What are you trying to accomplish by making your list of internal
commands?

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com
Modern cyberspace is a deadly festering swamp, teeming with
dangerous programs such as "viruses," "worms," "Trojan horses,"
and "licensed Microsoft software" that can take over your
computer and render it useless. --Dave Barry
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

Thanks to all who replied.

I have tried
Start | Run | hh ntcmds.chm

but all it displays is the following text:
---------------------
About this Help file
The topics in this Help file are integrated into Help and Support
Center.
To view these topics, click Start, and then click Help and Support.
---------------------

I am trying to emulate the Unix 'which' command under WinXP by writing
a small
program.
Given a random word (for example 'SORT'), the program scans PATH and
PATHEXT to find all occurences of 'SORT.EXE', SORT.BAT',
'SORT.<whatever-is-specified-in-PATHEXT>' in all directories specified
in PATH.
That part works fine, but if I feed the word 'DIR' to my program, it
obviously can't find any 'DIR.*' anywhere in the directories specified
in PATH.
However, I want my program to identify 'DIR' as an internal command,
and to do so, I need (in one form or another) an exhaustive list of all
internal commands.
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

[[Generally, the distinction between internal and external commands is
unimportant, except that internal commands have no associated executable
file.

The following are all of the Windows NT internal commands:

ASSOC CALL CHDIR/CD CLS COLOR COPY DATE DIR
DPATH ECHO ENDLOCAL ERASE/DEL EXIT FOR FTYPE GOTO
IF MKDIR/MD MOVE PATH PAUSE POPD PROMPT PUSHD
REM RENAME/REN RMDIR/RD SET SETLOCAL SHIFT START TIME
TITLE TYPE VER ]]
From...
The Windows NT Command Shell
By Tim Hill
http://www.microsoft.com/technet/prodtechnol/winntas/deploy/shellscr.mspx

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In news:1118913425.277848.118210@f14g2000cwb.googlegroups.com,
gov <gov300z@yahoo.com> hunted and pecked:
> Thanks to all who replied.
>
> I have tried
> Start | Run | hh ntcmds.chm
>
> but all it displays is the following text:
> ---------------------
> About this Help file
> The topics in this Help file are integrated into Help and Support
> Center.
> To view these topics, click Start, and then click Help and Support.
> ---------------------
>
> I am trying to emulate the Unix 'which' command under WinXP by writing
> a small
> program.
> Given a random word (for example 'SORT'), the program scans PATH and
> PATHEXT to find all occurences of 'SORT.EXE', SORT.BAT',
> 'SORT.<whatever-is-specified-in-PATHEXT>' in all directories specified
> in PATH.
> That part works fine, but if I feed the word 'DIR' to my program, it
> obviously can't find any 'DIR.*' anywhere in the directories specified
> in PATH.
> However, I want my program to identify 'DIR' as an internal command,
> and to do so, I need (in one form or another) an exhaustive list of all
> internal commands.
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.general (More info?)

Initially, I was thinking more in the lines of extracting this list of
internal commands directly out of "CMD.EXE" each time my program is
invoked, but I guess this approach would be quite complicated.

Anyway, I will incorporate the list of all the Windows NT internal
commands as a hardcoding into my program. This should resolve my
problem.