Which switch should be used in the DIR command to view files in all directories ?
/S switch should be used in the DIR command to view files in all directories.
In computing, dir (directory) is a command used for computer file and directory listing, specifically in the command line interface (CLI) of the operating systems CP/M, MP/M, DOS, OS/2, Singularity, Microsoft Windows, ReactOS, and in the DCL command line interface used on VMS, RT-11 and RSX-11.
To do this, open a command prompt from the keyboard by typing Win+R, or click on Start \ Run then type cmd in the run box and click OK. Navigate to the folder you want displayed in Windows Explorer by using the Change Directory command "cd" (with out the quotes).