ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   macro (https://www.excelbanter.com/excel-programming/429517-re-macro.html)

Don Guillett

macro
 
Here is one I use for different checking accounts 1,2,or 3. Right click
sheet tabview codemodify to suit.

Private Sub Worksheet_Change(ByVal Target As Excel.Range)

If Target.Address < "$E$4" Then exit sub
On Error Resume Next
mn = Choose([e4], 1, 2, 3)
If mn = 0 Or [e4] = "" Then
Selection.AutoFilter Field:=5
Else
Selection.AutoFilter Field:=5, Criteria1:=mn
End If

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Stefan" wrote in message
...
Hi,

I´m looking to create a macro that will do the following procedu

If column b2:b45 contains the value "Role 1" and "all" show rows
containing
values.

I will use a dropdown list with macros with role 1, role 2...

Regards
Stefan




All times are GMT +1. The time now is 10:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com