Bulk Delete Excel Blank lines

Source: Internet
Author: User
Tags empty first row

In the use of Excel statistics and analysis of objects, the data input can not be achieved overnight, record add, delete, cut, merge is indispensable, after several edits to modify the process, in the table will often appear many empty lines. The presence of these empty lines is both unattractive and affects the results of data analysis, which are usually deleted. If there are fewer empty rows in the table, you can delete them one line at a time, but if the worksheets are large (such as thousands of rows), and many of the empty rows in the table are blank, manually deleting them in one row is a time-consuming effort. If you often encounter this kind of trouble, try these methods, you can quickly, cleanly, batch to clean out the nominal empty line.

Locate method

Table edit complete, click "Edit/Position" in the menu bar when you want to delete the empty rows in the box, and then in the "locate" button in the pop-up "positioning" dialog. In the next Pop-up positioning Criteria dialog box, select the null value radio by item and click OK. OK, now look again, all the blank lines in the table are all selected and shown in blue. Click "Edit/Delete" in the menu bar to see that the blank line in the table has disappeared without a trace.

Tip: When you use this method to delete, make sure that all cells in other non-empty rows are filled with values, otherwise empty values in non-null rows are deleted, which directly results in a completely confusing table format.

   "Filter" method

If there are items in the table that are not filled in, you must filter the blank rows of the table before you delete them by using the filter feature.

First step: First position the mouse over the top of the worksheet, and then insert a new blank row in the table. Then insert a new empty column at the leftmost edge of the worksheet, enter "1" in the first single grid, and then drag the automatic fill handle to populate the previous sequence with the column. This is done primarily to prepare for the next step of screening, because Excel can only recognize contiguous rows while filtering, encountering empty rows does not continue filtering down, so before filtering, we insert a column in the table with the most left in it, filling a simple sequence in the column to make the table contiguous.

Step two: Next, press the "CTRL + a" key to select the entire worksheet. Click the data/Filter/AutoFilter command in the menu bar.

Step three: At the top of each column, a drop-down list box appears, select a column, click its drop-down list box, and choose Blank. If there are rows of data in the page, select another column and choose Blank from its Drop-down list box until the data is not visible in the page.

The fourth step: OK, this time the rest of the page is blank line, select the "Edit" menu, choose "Delete Rows" command on it.
Step Fifth: When all the blank lines have been deleted, and then click Data/Filter/AutoFilter, the data on the worksheet is restored, and then the column that you inserted on the left is deleted.

Tip: To insert a blank line at the beginning of the operation, one is to avoid deleting the first row of data. The second is that when the worksheet has a header row, the Drop-down list box appears only when the AutoFilter command is selected.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.