I'll answer the second part first:
* In TWC, macros don't generate text output. They generate and render DOM elements. Thus, you cannot use the output of a macro as a parameter of another macro.
* In TW5, macros are used to assemble text output and the returned value can, with syntax limitations, be used as a parameter of another macro.
Now on to the real tech:
"new Date()" returns the current date/time in milliseconds since midnight on Jan. 1, 1970 (the start of time, computationally speaking!). As you've learned, this value can then be formatted using .formatString ('YYYY0MM0DD').
To use a date other than the current one, pass the number of milliseconds into the Date() function. For example, if you use new Date(0).formatString(...), you will see "19700101". (note: the date is adjusted for your local time zone, so if you are west of UDT, the start date will show as "19691231")
You can calculate a new value from the current date/time value by adding/subtracting the appropriate number of milliseconds. For example, one day is 86400000 milliseconds (60 x 60 x 24 x 1000). Thus, to get tomorrow's date, you would use "new Date() + 86400000" as the input param, like this:
new Date(new Date() + 86400000).formatString('YYYY0MM0DD 0hh:0mm:0ss');
enjoy,
-e
Eric Shulman
ELS Design Studios
TiddlyTools - "Small Tools for Big Ideas!"
InsideTiddlyWiki: The Missing Manuals
YOUR DONATIONS ARE VERY IMPORTANT!
HELP ME TO HELP YOU - MAKE A CONTRIBUTION TO MY "TIP JAR"...
Professional TiddlyWiki Consulting Services...
Analysis, Design, and Custom Solutions: