Drop down list opens new window
Closed
bzg51n
TrowaD
- Posts
- 1
- Registration date
- Saturday April 26, 2014
- Status
- Member
- Last seen
- April 26, 2014
TrowaD
- Posts
- 2880
- Registration date
- Sunday September 12, 2010
- Status
- Moderator
- Last seen
- May 2, 2022
Related:
- Drop down list opens new window
- In excel how to create a drop down list - Guide
- Excel 2007 drop down list not working ✓ - Forum - Excel
- Excel drop down list changes other cells ✓ - Forum - Excel
- List open ports: Windows, Linux - Guide
- How to create a drop-down List in Excel - Guide
1 reply
TrowaD
Apr 28, 2014 at 12:04 PM
- Posts
- 2880
- Registration date
- Sunday September 12, 2010
- Status
- Moderator
- Last seen
- May 2, 2022
Apr 28, 2014 at 12:04 PM
Hi bzg51n,
In the code below the drop down list (ddl) is located in A1. The ddl contains the values "a" and "b" and those are also the sheet names:
Right-click on sheets tab and select view code to paste the code to.
Best regards,
Trowa
In the code below the drop down list (ddl) is located in A1. The ddl contains the values "a" and "b" and those are also the sheet names:
Private Sub Worksheet_Change(ByVal Target As Range) If Intersect(Target, Range("A1")) Is Nothing Then Exit Sub If Target = vbNullString Then Sheets("a").Visible = False Sheets("b").Visible = False End If If Target = "a" Then Sheets("a").Visible = True Sheets("b").Visible = False End If If Target = "b" Then Sheets("b").Visible = True Sheets("a").Visible = False End If End Sub
Right-click on sheets tab and select view code to paste the code to.
Best regards,
Trowa