How to auto display a default value while deleting value in drop-down list in Excel?
In Excel, you can create a drop-down list for users to select value from the list by using Data Validation. But in some cases, you may want to display a default value such as -select- in the drop down list cell instead of blank while the selected item has been deleted as below screenshot shown. In this article, I introduce a method on solving this job in Excel.
1. Right click at the sheet tab which contain the drop-down list you use, then click View Code in the context menu.
2. In the popping Microsoft Visual Basic for Applications window, copy and paste below code to the blank script.
VBA: Display default value while deleting selected item in drop down list
Private Sub Worksheet_Change(ByVal Target As Range) Dim xObjV As Validation On Error Resume Next Set xObjV = Target.Validation If xObjV.Type = xlValidateList Then If IsEmpty(Target.Value) Then Target.Value = "-Select-" End If End Sub
3. Then save this code. Now after deleting the selected items first time, the default value will be displayed until item is selected in the drop-down list.
Tabbed browsing & editing multiple Excel workbooks/Word documents as Firefox, Chrome, Internet Explore 10!
You may be familiar to view multiple webpages in Firefox/Chrome/IE, and switch between them by clicking corresponding tabs easily. Here, Office Tab supports similar processing, which allow you to browse multiple Excel workbooks or Word documents in one Excel window or Word window, and easily switch between them by clicking their tabs. Click for free 45-day trial of Office Tab!