Automatic Entry of the Date

Thanks to Sandro for providing this very useful little macro (Excel and Mac compatible) for YNAB 3.1.

Do you get sick and tired of typing in today’s date when entering transactions in the Register? This little macro will do the work for you. Here’s out to get it running:

  1. With YNAB open, press Alt+F11
  2. 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 Sheet3 (Register)
  3. 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
  4. 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.
  5. In between these two lines, paste the following code:
    If Target.Column = 3 Then
    If Range("B" & Target.Row).Value = "" Then
    Range("B" & Target.Row).Value = Now
    End If
    End If
  6. Click the Save button in the Visual Basic Editor and close it.

Alright, you should be finished. Now give it a test drive. When you click on a blank “Category” cell, the “Date” cell to the left of it will be filled in with today’s date! Thanks again Sandro!

No Comments

[Leave a comment]

RSS feed for comments. TrackBack URL

Leave a comment

Thank you for your comment!

About

Picture of Jesse

This is The Wallet. My name is Jesse Mecham, founder of YNAB. Here I focus on the YNAB methodology, software, personal finance, and more.

Take the Tour or download the trial to see what YNAB's all about.

Follow me on Twitter Whiteboard Wednesdays, Sneak Peeks, and More! Friend me on Facebook Subscribe to my blog's RSS feed

What's New?

YNAB on Your iPhone

Popular Posts

Archives

Categories

Bloggers Using YNAB

The YNAB Way

YNAB Online Classes

Live Online Classes

  • - Live Instruction
  • - Small class sizes
  • - Open Q & A

Register

(FREE)
YNAB Online Classes

YNAB University

  • - Learn to master your money!
  •  

Start

(FREE)
YNAB for iPhone

YNAB for iPhone

  • - On-the-go transaction entry
  • - Check your budget
  • - Sync to YNAB for Desktop

YNAB for iPhone