Ah OK !!
Thanks very much
On Wednesday, August 21, 2019 at 5:29:33 PM UTC+2, Mark S. wrote:
>
> Text substitution (e.g. $(myvariable)$ ) only happens inside of macros. So
> you need to define a macro.
>
> This version seems to work:
>
> \define mymacro() <$action-setfield $tiddler=
> "$:/plugins/vpl/jazzbokMem/DbActivity" $index=<<now $(myVariable)$ >>
> $value="hello" />
>
> <$button>
> <$set name="myVariable" value={{!!date-format}}></$set>
> Test<<mymacro>>
> </$button>
>
> Good luck!
>
> On Wednesday, August 21, 2019 at 6:48:28 AM UTC-7, vpl wrote:
>>
>> Hi
>>
>> A stupid question ... but how to pass a variable to a macro in wikitext
>> I can't find any example
>>
>> <$button>
>> <$set name="myVariable" value={{!!date-format}}></$set>
>> <$action-setfield $tiddler="$:/plugins/vpl/jazzbokMem/DbActivity";
>> $index=<<now $(myVariable)$ >> $value="hello" />
>> Test
>> </$button>
>>
>> My date-format field contains "YYYY-0MM-0DD:hh:0mm:0ss"
>> When I click on the button this action populate the data-tiddler with the
>> following content
>> {
>>
>> "$(myVariable)$": "hello"
>>
>> }
>>
>>
>> Where I'm expecting
>>
>> "2019-08-21:15:20:09": "hello"
>>
>>
>> Any idea would help me a lot
>>
>>
>> Thanks for your support
>>
>>
>> Vpl
>> ",
>>
>>
--
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 view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/2e048617-26c2-42f9-b34a-635e0dd79a2c%40googlegroups.com.