How to Overline Text in Excel (4 Method)

Method 1 – Using the Accent Option

  • Click the Insert tab.
  • Click on Symbols followed by Equation.

  • Choose Accent and select Bar.

Use Accent Option to Overline Text in Excel

  • A text box with a Bar on the top will appear.

  • Enter your desired text in the text box. The bar will appear over the text.

Use Accent Option to Overline Text in Excel

  • Drag the text box to your desired cell and adjust its size.
  • You’ll get overlined text in the cell.

Use Accent Option to Overline Text in Excel


Method 2 – Combining REPT, LEN, and CHAR Functions

  • Insert a column named Overlined Text.
  • Select the entire column and turn on Wrap Text from the Home tab.

  • Enter the following formula in cell D5:
=REPT("_",LEN(C5))&CHAR(10)&C5
Formula Breakdown
  • CHAR(10) adds a line break in the cell.
  • LEN(C5) returns the number of characters in a text string. It will return 8 in this case.
  • REPT(“_”,LEN(C5))&CHAR(10)&C5 repeats the “_” symbol 8 times as the number of characters is 8 in cell C5.

Combine REPT, LEN, and CHAR Functions to overline text in Excel

  • Press Enter to create overlined text.

Combine REPT, LEN, and CHAR Functions to overline text in Excel

  • AutoFill the formula to the other cells in column D.

how to overline text in excel


Method 3 – Using Keyboard Shortcuts

  • Enter “_” before the text in your desired cell.
  • Repeat the symbol for each character you want to overline.

  • Keep the cursor between the symbols and text.
  • Press Alt+Enter to add a line break.

Apply Keyboard Shortcuts to Put a Line over Text in Excel


Method 4 – Insert Shapes Feature to Overline Text in Excel

  • Go to the Insert tab.
  • Click on Shapes followed by Lines

  • Use your mouse to draw a line above the text.

  • Customize the line color and width.

Insert Shapes Feature to Overline Text in Excel

Notes
  • Adjust the cell height to make the overlined text visible.
  • Ensure proper cell references for desired results.

Download Practice Workbook

You can download the practice workbook from here:


Related Articles


<< Go Back to Text Formatting | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Alif Bin Hussain
Alif Bin Hussain

Alif Bin Hussain earned a BSc in Civil Engineering from Bangladesh University of Engineering and Technology. As an engineering graduate, he has a deep passion for research and innovation. He loves to play with Excel. In his role as an Excel & VBA Content Developer at ExcelDemy, he not only solves tricky problems but also shows enthusiasm and expertise in handling tough situations with finesse, emphasizing his dedication to delivering top-notch content. He is interested in C, C++,... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo