Walk a directory/Non-recursively: Difference between revisions

→‎{{header|Batch File}}: Added syntax highlight
(→‎{{header|Batch File}}: Added syntax highlight)
Line 97:
=={{header|Batch File}}==
A simple command that displays all EXE files in System32 directory non-recursively.
<lang dos>@dir /b "%windir%\system32\*.exe"</lang>
The same command inside FOR loop:
*Inside a Batch File:
<lang dos>@for /F "tokens=*" %%F in ('dir /b "%windir%\system32\*.exe"') do echo %%F</lang>
*Command-line:
<lang dos>for /F "tokens=*" %F in ('dir /b "%windir%\system32\*.exe"') do echo %F</lang>
 
=={{header|BBC BASIC}}==
535

edits