Here’s a sample dataset containing PC parts, prices, and available quantities. We’ll change the column headings in the file from letters to numbers.
Method 1 – Using the R1C1 Reference Style to Change Column Headings in Excel
Steps:
- Calculate the total prices in the data set.
- Apply the following formula to determine the total price per product.
=C5*D5
- In the formula, the cell references contain column letters in them, which are C5 and D5.
- Press Enter and AutoFill the formula into the cells below.
- Go to the File tab of the ribbon.
- Select Options.
- You’ll get the Excel Options dialog box.
- Go to the Formula tab of the box and check the option R1C1 reference style.
- Select OK.
- Go back to your worksheet.
- The column labels in the worksheet will turn into numeric values.
Read More: How to Create Column Headers in Excel
Method 2 – Applying Excel VBA to Change Column Headings
Steps:
- Calculate the total price again by using the following formula.
=C5*D5
- The column labels are in alphabetical order.
- Go to the Developer tab of the ribbon.
- Choose the Visual Basic command from the Code group.
- The VBA window will appear.
- Select Module from the Insert tab.
- Copy the following code into the module of the VBA window.
'Set the name of the function
Sub Changing_Column_Headings()
'Altering Reference Style from Letter to Number
Application.ReferenceStyle = xlR1C1
End Sub
- Save the code and press the play button or F5 to run the code.
- After running the code, the reference style of column headings will turn into the R1C1 reference style.
- This reference style will transform the column headings from letters to numbers.
Read More: How to Remove Column1 and Column2 in Excel
Download the Practice Workbook
Related Articles
- How to Rename Column in Excel
- How to Remove Column Headers in Excel
- How to Title a Column in Excel
- How to Change Excel Column Name from Number to Alphabet
- How to Create Excel Table with Row and Column headers
- How to Repeat Column Headings on Each Page in Excel
- [Fixed] Excel Column Numbers Instead of Letters
<< Go Back to Rows and Columns Headings | Rows and Columns in Excel | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!