Tinderbox Forum

Using OnAdd to Mark Things "Done"

After reading Dean Pribetic’s blog post on GTD and Tinderbox, I’ve been playing with my own “Horizon View” TBX map.

Right now, I’d like to add an attribute $Done with the current timestamp when I drag a note or an alias to a note labeled “Archive.” Here’s a screenshot so you can see the interaction I hope to achieve.

I’ve looked up OnAdd and date(“today”) and I’ve tried several things, but odd things are happening and so I thought I’d come here to see if there might be someone who can suggest a couple stepwise things I might do to get it work.

Does this work?


Adding the $Prototype in the on-add action isn’t necessary, but I find it useful. (For completeness, this is normally how $OnAdd is defined – using the Action Inspector. Though, it can be done other ways.)

Archive.tbx (75.4 KB)

Hi Beck!

I also got this to work on my end:

Hopefully that helps with what you’re looking for.

I swear I did this exactly and it didn’t work and now it does (yours and mine). Thanks for the magic!

1 Like

This works as well! And I wasn’t aware of the quickstamp feature here, either. Thanks, Derek!

FWIW, and not to critique @derekvan’s example, the best practice for setting a date either as a string (e.g. “1 Oct 2018” or such) or as a designator like today is to use date(). Thus:

$Done = date("today");

The designators “now” and “today” both give the same result. Double quotes or single quotes can be used around the string. Double seems just to be the prevailing practice.


1 Like