Hi Jeremy,

I tried to reproduce a simple example though may seem meaningless.


\define utility(a, b) This is //$a$//  and ''$b$''.

\define test(tidName, v1, v2)
<$wikify name="newText" 
text="""<$macrocall $name="utility"
a=<<__v1__>> b=<<__v2__>>
/>""">
<$action-setfield $tiddler="""$tidName$""" $field="text" $value=<<newText>> 
/>
</$wikify>
\end

<$button>Do it
<<test "myTiddler" italic bold>>
</$button>


What I expect is to see the myTiddley text field as

This is //italic//  and ''bold''.



But I see this

This is italic and bold.


--Mohammad

PS: The real story is I am developing a code to search and replace a string 
in a tiddler text field.





On Thursday, February 21, 2019 at 5:43:34 PM UTC+3:30, Jeremy Ruston wrote:
>
> Hi Mohammad
>
> Please could you post a complete example?
>
> Many thanks,
>
> Jeremy
>
> On 21 Feb 2019, at 14:06, Mohammad <mohammad...@gmail.com <javascript:>> 
> wrote:
>
>
> One way to store the result of a macro has some parameters is to store it 
> in wikified variable as below
>
>
> Example
> See the below code extracted from a longer code. This works correctly. It 
> calls utility, and save the results in newText and then the action-setfield 
> passes it to a tiddler as its text field.
>
>
> <$wikify name="newText"  text="""<$macrocall $name="utility" par1=<<val1>> 
> par2=<<val2>> />""" >
> <$action-setfield $tiddler="""$tidName$""" $field="text" $value=<<newText>> 
> />
>
> </$wikify>
>
>
>
> Now, assume the *result *of *utility macro *is something like below
>
> This is //italic// and this is {{!!caption}}
>
>
> What happens? $Wikify save the wikified result as expected, but I wish to 
> store in tidName text filed the raw non-wikified result, I mean what 
> exactly *utility  macro *returns.
>
> So, the question is how can I store the result of *utility macro* in 
> non-wikified (raw form) and pass it to the text filed of some tiddler?
>
>
> --Mohammad
>
> -- 
> 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 tiddlywiki+...@googlegroups.com <javascript:>.
> To post to this group, send email to tiddl...@googlegroups.com 
> <javascript:>.
> 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/099d67c2-8bb2-41c9-a372-f0948167bf41%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/tiddlywiki/099d67c2-8bb2-41c9-a372-f0948167bf41%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
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 tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
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/3f5cf631-8ae6-4096-bdcf-c328891cee48%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to