Add-in: Highlight active category (2.02 or later)
- December 30th, 2005
- Miscellaneous
A few customers have mentioned it would be nice to have some type of marker on the Budget sheet that shows which category you’re dealing with when you’re budgeting. I thought this was a nice idea for an optional add-in. Here’s a little shot of what it will look like once installed:

- With YNAB open, press Alt+F11
- You’re now in the Visual Basic Editor. On the left side there is a pane called “Project - VBA Project” (if it’s not visible press Ctrl+r). Double-click on Sheet2 (Budget)
- A white page will open to the right. There are two drop-down boxes at the top of the just-opened page. In the left drop-down box select Worksheet
- The right drop-down box should automatically say SelectionChange and you should see two lines that have automatically been entered: Private Sub Worksheet_Selection… and End Sub.
- In between those two lines, paste the following code:
If (Target.Column >= 2) And (Target.Column < = 78) Then
If (Target.Row <= 126) And (Target.Row >=
Then
Range(”A8:A126″).Interior.ColorIndex = 15
Range(”A” & Target.Row).Interior.ColorIndex = 38
End If
End If - Click the Save button in the Visual Basic Editor and close it.
Note that this is for version 2.02 3.0 or later. Give it a test run and see how you like it. Any modifications are, of course, totally up to you.

