In my project I need to first create a new project with an identifier (an 
input data) then to offer a complete input of the project to the user.

I have crafted this macro invoked when the identifier is ready to be used.

\define insertProject(proto)
<$set name=project select=0 filter="[all[current]getindex[project]]">
  <$action-setfield $tiddler=<<target>> $index=<<project>> $value=""/>
  <$set name=autoref select=0 filter="[<project>addsuffix[/project]]">
  <$action-setfield $tiddler=<<target>> $index=<<autoref>> 
$value=<<project>>/>
  <$macrocall $name=editProject proto="$proto$" target=<<target>> 
id=<<project>>/>
</$set>
\end

this does indeed create an index within the data tiddler with the desired 
value. Then it prepares the data for the further input. So far so good. But 
the second input does nothing. With additional logging, it is shown that in 
fact this last part is called first! (this is the call to editProject).

I wonder wether that is but an illustration that in TW the order of the 
treatments cannot be guaranteed?

Anyway. can I achieve my goal? And how?

In the meantime, I'll just setup a message to do the edit by hand.

Could we dream of callbacks for action, that would be called after the 
action is done?

something like <$macrocall $name=insertProject $chaining=editProject/>

surely it would use variable instead of parameters as a way not to have too 
cumbersome a syntax in the macrocall. And it may very well not be on offer 
for a direct call like <<insertProject>>.

Regards.

-- 
Jean-Pierre

-- 
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/4f0c3abf-a515-4b5a-861a-1241b6e01e31n%40googlegroups.com.

Reply via email to