[tw5] field manipulation, lookup's lists and maths!

I am afraid once more I find myself out of my depth and hope you guy’s and gals can help…

I have a Tiddler, on that tiddler I have a number of fields. The names of those fields are of the format another.tiddler.name where a tiddler exists called Another Tiddler Name. I am able to reformat another.tiddler.name into Another Tiddler Name through a macro that looks like this;

\define replaceFullStopAndCapitalize(text)
@@text-transform: capitalize;<$text text={{{ [[$text$]search-replace:gi[.],[ ]] }}} />@@
\end

I am able to list the fields using a filter like this “[all[current]fields[]sort[title]] -text -created -modified -tags -title -tmap.id” with a variable which I can then pass to that macro.

What I need to do, is get the cost field from those other tiddlers and sum them up… I think it should be possible using the “Formular for TiddlyWiki” Plugin found here GitHub - EvanBalster/TiddlyWikiFormula: Functional Formulas for TiddlyWiki, in the style of Excel and Google Sheets

The closest I have been able to get is this

<$list filter="[all[current]fields[]sort[title]] -text -created -modified -tags -title -tmap.id" variable=“listItem”>
<$transclude tiddler="<$macrocall $name=“replaceFullStopAndCapitalize” text=<>/>" field=“cost”/>
</$list>

Which renders as

<$transclude tiddler=“Another Tiddler Name” field=“cost”/>

and If I copy/paste that into a normal tiddler, it shows the right value.

1 Like

Hi,

You should consider to enter the forum at talk.tiddlywiki.org … There will be a much greater audience for your questions.

-m

1 Like