Complete writeup, as requested, has now been posted in the macros forum here.