Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, 2016, 2019, and Excel in Office 365. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Forcing Editing to Be Done in a Cell.
by Allen Wyatt
(last updated November 16, 2019)
Rodolfo knows that he can configure Excel to allow editing in both the Formula bar and the cell itself, but he wants to configure it so that editing can be done only in the cell, not in the Formula bar.
There is no way to do this in Excel. The closest you can come is to make sure that cell editing is enabled (so that editing can be done in either the Formula bar or the cell) and then hiding the Formula bar. You can hide the Formula bar by these steps:
Figure 1. The Advanced options in the Excel Options dialog box.
If you prefer, you can also programmatically turn off the Formula bar for a specific worksheet. You can do this by using the following two macros, which should be assigned to the code for the specific worksheet you want to affect. (You can display the proper code window by right-clicking the worksheet's tab and selecting View Code from the resulting Context menu.)
Private Sub Worksheet_Activate() Application.DisplayFormulaBar = False End Sub
Private Sub Worksheet_Deactivate() Application.DisplayFormulaBar = True End Sub
The first macro turns off the Formula bar when the worksheet is activated, and the second turns it back on when the worksheet is deactivated (when another worksheet is selected).
ExcelTips is your source for cost-effective Microsoft Excel training. This tip (9095) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, and Excel in Office 365. You can find a version of this tip for the older menu interface of Excel here: Forcing Editing to Be Done in a Cell.
Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!
Need to limit the number of characters that can be entered into a cell? One easy way to do it is through the use of Data ...Discover More
Excel supports several types of dashes. This tip describes those different types and explains how to enter them in a cell.Discover More
If you need to swap the contents of two cells in your worksheet, Excel provides a number of ways you can approach the ...Discover More
FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."
Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.