logo

How to Get a List of Files from Command Prompt in Windows 📂Programing

How to Get a List of Files from Command Prompt in Windows

Overview

When putting together a program that aggregates multiple sets of data, having too many files can be problematic. Naturally, every programming language has its own solutions, but temporary fixes often greatly assist when there is no need to repeat or when using a wide variety of languages. Let’s see how to do this quickly and easily using Windows Command Prompt.

Guide

Step 1. Copy the Address

20190503\_152207.png

Enter the folder where the file list is needed and copy the address. In Windows Explorer (and actually in Ubuntu Nautilus as well), pressing Ctrl+L highlights the full address. Using the shortcut Ctrl+LCtrl+C allows for quickly copying the address.


Step 2. CMD

20190503\_152535.png

In CMD,

cd (주소)

enter to navigate to the specified path.


Step 3.

20190503\_152730.png

In CMD,

dir /b

enter, then drag and copy to obtain the list of files.