Skip to main content
 

How to create list from range in Excel?

Author: Sun Last Modified: 2024-07-30

You may need to create a list by a range of data frequently, for instance, a range of data on 24 solar terms as shown as below. Of course, you can copy and paste them into a list manually, but it seems somewhat tedious if there are many columns in the range. Actually, there are a couple of tricks to create a list from specified range in Microsoft Excel easily.

create list from range sample data

Create list from range with VBA

Create list from range with Kutools for Excel


arrow blue right bubble Create list from range with VBA

In Excel, you also can use VBA code to quickly import a list or range.

1. Hold ALT button and press F11 on the keyboard to open a Microsoft Visual Basic for Application window.

2. Click Insert > Module, and copy the VBA into the module.

VBA: Create list from range

Sub UniqueList()
'Updateby20140304
Dim InputRng As Range, OutRng As Range
xTitleId = "KutoolsforExcel"
Set InputRng = Application.Selection
Set InputRng = Application.InputBox("Range:", xTitleId, InputRng.Address, Type:=8)
Set OutRng = Application.InputBox("OutPut to (single cell):", xTitleId, Type:=8)
For i = 1 To InputRng.Rows.Count
    For j = 1 To InputRng.Columns.Count
        OutRng.Value = InputRng.Cells(i, j).Value
        Set OutRng = OutRng.Offset(1, 0)
    Next
Next
End Sub

3. Click Run button or press F5 to run the VBA. A dialog displayed on the screen, and select the range of data that you will create a list with. See screenshot:

create list from range vba code 1

5. Click OK, select a cell to output the list from the pop-up dialog, then click OK. See screenshot:

create list from range vba code 2

Then the range of data has been created as a list in the selected cell.

create list from range vba code result


arrow blue right bubble Create list from range with Kutools for Excel

The handy tool – Kutools for Excel's Transform Range function also can quickly and easily create a list from a range data.

Kutools for Excel includes more than 300 handy Excel tools. Free to try with no limitation in 30 days. Get it Now

1. Select the data range you want to create it as a list, and click Kutools > Range > Transform Range. See screenshot:

2. In the pop-up Transform Range dialog, check Range to single column, and click OK, another dialog displayed for you to select a blank cell to output the list, click OK. See screenshot:

create list from range with kutools 1
arrow
create list from range with kutools 2

3. Then the list is created.

Click here for more information about Transform Ranges.

Best Office Productivity Tools

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates   |  Delete Blank Rows   |  Combine Columns or Cells without Losing Data   |   Round without Formula ...
Super Lookup: Multiple Criteria VLookup    Multiple Value VLookup  |   VLookup Across Multiple Sheets   |   Fuzzy Lookup ....
Advanced Drop-down List: Quickly Create Drop Down List   |  Dependent Drop Down List   |  Multi-select Drop Down List ....
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Ranges & Columns ...
Featured Features: Grid Focus   |  Design View   |   Big Formula Bar    Workbook & Sheet Manager   |  Resource Library (Auto Text)   |  Date Picker   |  Combine Worksheets   |  Encrypt/Decrypt Cells    Send Emails by List   |  Super Filter   |   Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters, ...)   |   50+ Chart Types (Gantt Chart, ...)   |   40+ Practical Formulas (Calculate age based on birthday, ...)   |   19 Insertion Tools (Insert QR Code, Insert Picture from Path, ...)   |   12 Conversion Tools (Numbers to Words, Currency Conversion, ...)   |   7 Merge & Split Tools (Advanced Combine Rows, Split Cells, ...)   |   ... and more

Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time.  Click Here to Get The Feature You Need The Most...


Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!