Microsoft Office Online
Sign in to My Office Online (What's this?) | Sign in

 
 
Help and How-to
Search
Search
 
 
 
 
Warning: You are viewing this page with an unsupported Web browser. This Web site works best with Microsoft Internet Explorer 6.0 or later, Firefox 1.5, or Netscape Navigator 8.0 or later. Learn more about supported browsers.

Import only columns that contain data
 
  1. In Step 2 of the Text Import Wizard, do one of the following:
    • For delimited columns, click the character the file uses to separate the columns under Delimiters, and then select the Treat consecutive delimiters as one check box.
    • For fixed-width columns, set break lines to indicate the divisions between the columns. If a column contains no data, do not set a break line to separate it from the previous column.
  2. Click Finish. In the Import Data dialog box, make sure Existing worksheet is selected and the box contains =$A$1, and then click OK.

For delimited columns, be sure to check your results in Excel. If any of the columns are blank in some of the rows but contain data in other rows, the data might not be importing to the right columns. If this happens, try skipping the columns you don't need to import.

Note  You can access the Text Import Wizard any time you need to by pointing to Get External Data on the Data menu, clicking Import Text File, and, in the Import Text File dialog box, locating your file and then clicking Import.

Refreshing the data when your text file changes

After you complete importing the data and saving your workbook, Excel will remember the steps you followed and all of your import settings, including which columns go on which worksheet and which columns you skipped. When you get an updated text file, follow the steps below to import the new data:

  1. In the Excel workbook, click a cell in the range of imported data. The External Data toolbar appears.
  2. On the External Data toolbar, click the Refresh Data button.
  3. In the Import Text File dialog box, locate the updated version of the text file, and then click Import.

More information

For more information about importing text files, type importing text in the Office Assistant or on the Answer Wizard tab in the Excel Help window, and then click Search.

For more information about working with external data ranges, type formatting external data ranges in the Office Assistant or on the Answer Wizard tab in the Excel Help window, and then click Search.

advertisement