Thank you very much! It worked like a charm! I'm also really sorry to ask yet another question but for some reason the solution isn't clicking just yet. I've been searching all morning trying to find the right combination/solution and while I have made a little progress I think I'm mixing too many functions together. The below code is slightly modified from the original one above due to having a different but related purpose.
\define temp() $:/temp/input/$(currentTiddler)$ | Story Name:|<$edit-text tiddler=<<temp>> field="storyname"/> | | Story Abbreviation:|<$edit-text tiddler=<<temp>> field="storyabbrev"/> | <$tiddler tiddler=<<temp>>> <$button> Create Story <$action-setfield $tiddler={{!!storyabbrev}} text={{!!tocscript}} tags=Stories /> <$action-setfield $tiddler={{{ [{!!storyabbrev}addsuffix[ Chapter 001]] }}} tags={{!!storyabbrev}} /> <$action-deletetiddler tiddler=<<temp>> /> </$button> </$tiddler> <div class="tc-table-of-contents"> <<toc-selective-expandable "{{!!storyabbrev}}" "sort[title]">> </div> I can't figure out how to: 1) Make the toc div text a variable, named toscript, to call it in the script like the fields, so I can add it to the new tiddler being created. 2) Update the tag name in the toc-selective-expandable macro before it is added to the new tiddler being created. Every time I try to use /define or $set I either break the existing code or <<tocscript>> {{!!tocscript}} $tocscript$ (can't figure out which one, if any, to use) doesn't "activate" I was also thinking of trying to use an existing tiddler to act as the template for the toc div text but I ran into issues with that as well. Thanks again and once again my apologies if these are simple questions. On Wednesday, June 9, 2021 at 2:37:26 AM UTC-4 Eric Shulman wrote: > On Tuesday, June 8, 2021 at 10:49:07 PM UTC-7 iamdar...@gmail.com wrote: > >> If I wanted to add/append some static text to the end of the target field >> value, how would I do so? >> > > Using filtered transclusion: > <$action-setfield $tiddler={{{ [{!!target}addsuffix[ Chapter 01]] }}} etc. > > if you want, you could add the suffix to the input table: > | Target suffix:|<$edit-text tiddler=<<temp>> field="suffix"/> | > > and then you would use: > <$action-setfield $tiddler={{{ [{!!target}addsuffix{!!suffix}] }}} etc. > > enjoy, > -e > > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/61f07ce2-3d73-47c2-bae2-fe68d940b6c6n%40googlegroups.com.