[tw5] Re: Cloning a Tiddler

2019-02-20 Thread Mohammad
Dear all, Thanks for all your help. I understood how cloning is possible and I hopw I can use it in TW-Commander. Cheers 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,

[tw5] Re: Cloning a Tiddler

2019-02-20 Thread @TiddlyTweeter
I found the action-setfield method of silent cloning very interesting. I had absolutely no idea that it existed andcan't find this behaviour mentioned in docs. I assume it works because cloning a title clones the tiddler in its context of running? Is it a lucky side effect, or part of plann

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread Thomas Elmiger
Mohammad, here’s a version that works. Note: There seems to be a bug in the documentation of https://tiddlywiki.com/#WidgetMessage%3A%20tm-close-tiddler where *param* is a parameter instead of *$param* (?) <$button> Do it <$list filter="[range[1,3]]" variable="item"> <$action-sendmessage $messa

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread FrD
Le mardi 19 février 2019 20:06:52 UTC+1, Mohammad a écrit : > > Hi Mark, > Yes, but I have to iterate over all fields. > Hi, No, you don't have to iterate over the fields ; it clones the template and gives the clone the title you pass. Regards FrD -- You received this message because you

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread 'Mark S.' via TiddlyWiki
Why do you need to iterate the fields? When you make a clone by renaming the title, all the fields get cloned too. Or at least that's what happened in my test. Thanks! -- Mark On Tuesday, February 19, 2019 at 11:06:52 AM UTC-8, Mohammad wrote: > > Hi Mark, > Yes, but I have to iterate over all

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread Mohammad
Seems this work to clone a tiddler batchwise \define clone(newTid,Template) <$action-createtiddler $basetitle=$newTid$ $savetitle="temp" /> <$list filter="[<__Template__>fields[]] -title" variable=fname > <$set name="fval" tiddler=<<__Template__>> field=<> > <$action-setfield $tiddler={{temp}} $fi

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread Mohammad
Hi Mark, Yes, but I have to iterate over all fields. By the way I found something through this question that seems buggy <$button> Do it <$list filter="[range[1,10]]" variable=item> <$action-sendmessage $message="tm-new-tiddler" title=<> tags="uu"> No go to Advanced serach /Filter and type [

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread Mohammad
Hi Thomas, This does not work <$button> Do it <$list filter="[range[1,10]]" variable=item> <$action-sendmessage $message="tm-new-tiddler" title=<> tags="uu"> <$action-sendmessage $message="tm-close-tiddler" param=<>/> On Tuesday, February 19, 2019 at 8:26:55 PM UTC+3:30, Thomas Elmiger wr

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread 'Mark S.' via TiddlyWiki
Per FrD Create a unique title (possibly title plus date stamp). Use action-setfield to create new tiddler with the new, unique title. -- Mark On Tuesday, February 19, 2019 at 3:14:17 AM UTC-8, Mohammad wrote: > > Hi, > Thanks FrD, the problem is it will overwrite the existing tiddlers. I am

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread Mohammad
Hi, Thanks FrD, the problem is it will overwrite the existing tiddlers. I am looking to see how to clone as Tony said in his post. Cheers Mohammad On Tuesday, February 19, 2019 at 1:03:53 PM UTC+3:30, FrD wrote: > > Hi, > > Have a look at : > > https://groups.google.com/d/msg/tiddlywiki/swbra9E

[tw5] Re: Cloning a Tiddler

2019-02-19 Thread FrD
Hi, Have a look at : https://groups.google.com/d/msg/tiddlywiki/swbra9EhOm4/dQk3YpsPAQAJ Delete the part where you remove a field. The drawback is that you need to know the new title. Regards FrD Le mardi 19 février 2019 09:49:21 UTC+1, Mohammad a écrit : > > How is it possible to clone a ti