Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in


How to automatically create borders if a cell has contents in Excel?

You may add borders to cells with contents for outstanding the cell values in the worksheet by applying the All Borders option repeatedly. If it is time-consuming and boring for you to repeat the operation, this article will show you an easy method to automatically create borders if a cell has contents in Excel.

Automatically create borders if a cell has contents with Conditional Formatting

Automatically create borders if a cell has contents with Conditional Formatting

Please do as follows to automatically create borders if a cell bas contents in a range with Conditional Formatting.

1. Select a range you want to add borders to the cells when entering values. Then click Home > Conditional Formatting > New Rule. See screenshot:

2. In the New Formatting Rule dialog box, you need to:

2.1 Select use a formula to determine which cells to format option in the Select a Rule Type box.

2.2 Enter formula =C2<>"" into the Format values where this formula is true box.

2.3 Click the Format button. See screenshot:

Note: in the formula, C2 is the first cell of the selected range.

3. In the Format Cells dialog box, go to the Border tab, select the top, bottom, left and right border in the Border section, specify the line style as you need, and then click the OK button. See screenshot:

4. Then it returns to the New Formatting Rule dialog box, please click the OK button to finish the rule.

From now on, all borders will be added to cells automatically after value entered. See screenshot:

Related articles:

Recommended Productivity Tools for Excel

Kutools for Excel Helps You Always Finish Work Ahead of Time, and Stand Out From Crowd

  • More than 300 powerful advanced features, designed for 1500 work scenarios, increasing productivity by 70%, give you more time to take care of family and enjoy life.
  • No longer need memorizing formulas and VBA codes, give your brain a rest from now on.
  • Become an Excel expert in 3 minutes, Complicated and repeated operations can be done in seconds, 
  • Reduce thousands of keyboard & mouse operations every day, say goodbye to occupational diseases now.
  • 110,000 highly effective people and 300+ world-renowned companies' choice.
  • 60-day full features free trial. 60-day money back guarantees. 2 years of free upgrade and support.

Brings Tabbed Browsing and Editing to Microsoft Office, Far More Powerful Than The Browser's Tabs

  • Office Tab is designed for Word, Excel, PowerPoint and Other Office Applications: 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!
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.

Be the first to comment.