I wrote my two first macros. 

The first is a WikiText macro, but I think we have no control sentences 
like *if *or *for *loop in WikiText macros. I access all the tiddler 
fields: title, text, created, modified, tags....

The second is a Javascript macro because I need control sentences. But in 
it I don't know how to access to the current tiddler fields.
I try:

* return "Title: " + this.getFieldString(title);*

but it does not work.


This is the macro:
(function(){

"use strict";

exports.name = "ahora";

exports.params = [];

exports.run = function() {
 return "Title: " + this.getFieldString(title);
};

})();


and I call the macro in other tiddler in this way:

<$macrocall $name="ahora" />

I get: 


*Title: undefined     *: - (

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywikidev.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/2fe4e1c6-4a0d-42d2-baae-15e4b1294c40%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to