Thanks it does the job.
Nevertheless, it is so tricky ! and I really like tw5 and I think that, if
there is really no more intuitive way to deal with that, it deserves one.
Thanks all for developping all this useful stuff.
Le jeudi 26 janvier 2017 11:21:16 UTC+1, BJ a écrit :
>
> OK try this
>
> \define nextD(day)
> <$button>
> <$x-maketid $title={{fooTimeLine!!appointmentName}} tags="Date" text="a
> few comments"
> dueto={{fooTimeLine!!dueto}} end=<<dateTime ts:$day$ format:
> "YYYY0MM0DD0000000" add:"+1D">>/>
> MAKE IT
> </$button>
> \end
>
> ----
> <$macrocall $name="nextD" day={{fooTimeLine!!dueto}}/>
>
>
>
> On Thursday, January 26, 2017 at 8:26:12 AM UTC, peuhpeuh singe wrote:
>>
>> Thanks for your answer BJ. However, (and I maybe misunderstood something
>> in your solution) but it provides me the same result as my solution which
>> is that the created tiddler (with *title* {{fooTimeLine!!appointmentName
>> }}) as a field *end* that equals to "$macrocall $name="dateTime"
>> ts={{fooTimeLine!!dueto}} format="YYYY0MM0DD0000000" add="+1D"/> and not to
>> the corresponding subsitution. Any ideas ?
>>
>> Thanks in advance,
>> Peuph
>> Le mercredi 25 janvier 2017 18:46:35 UTC+1, BJ a écrit :
>>>
>>> HI Peuhpeuh,
>>>
>>> there are may ways to fix this, problably the easiest is to change the
>>> macro:
>>>
>>>
>>>
>>> \define nextDay(day)
>>> <$macrocall $name="dateTime" ts={{$day$}} format="YYYY0MM0DD0000000" add
>>> ="+1D"/>
>>> \end
>>> dateTime
>>> <$set name="end" value=<<nextDay "fooTimeLine!!dueto">>>
>>>
>>>
>>>
>>>
>>> all the best
>>>
>>> BJ
>>> On Wednesday, January 25, 2017 at 5:03:10 PM UTC, peuhpeuh singe wrote:
>>>>
>>>> Hello twexperts !
>>>>
>>>> I have a tiddler "fooTimeLine" with a field "dueto" containing a date
>>>> in tw format. I then want to create a button that is associated to the
>>>> creation of a new tiddler having as fields:
>>>> 1) "dueto" with the value in "fooTimeLine" and
>>>> 2) "end" with the value corresponding to the day after those of "dueto"
>>>>
>>>> My problem is with point 2). I use the nice dateTime macro
>>>> ($:/macros/skeeve/dateTime.js
>>>> at http://tiddlystuff.tiddlyspot.com) but I do not know how to resolve
>>>> the different macro evaluations:
>>>>
>>>>
>>>> \define nextDay(day)
>>>> <$macrocall $name="dateTime" ts=$day$ format="YYYY0MM0DD0000000" add=
>>>> "+1D"/>
>>>> \end
>>>> dateTime
>>>>
>>>> <$set name="end" value=<<nextDay {{fooTimeLine!!dueto}}>>>
>>>>
>>>> <$button>
>>>> <$x-maketid $title={{fooTimeLine!!appointmentName}} tags="Date" text="a
>>>> few comments"
>>>> dueto={{fooTimeLine!!dueto}} end=<<end>>/>
>>>>
>>>> Create
>>>> </$button>
>>>>
>>>> </$set>
>>>>
>>>>
>>>>
>>>> which does not work due to the fact macro consists in simple
>>>> substitution. I am ok with why it does not work but I do not know how to
>>>> tackle the problem without rewritting a dedicated macro and I thus request
>>>> your help : Can we deal with nested macro calls and how ?
>>>>
>>>
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/4ab39044-6743-4eb2-90d1-52f648ba577e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.