Mohammad, I had a look at it and changed and added some things, have a look at the attached file, try the replace-text-ui macro, simply
<<replace-text-ui>> if it works well, have a look how everything is done. I've called the snr macro snr123. I'm not fully sure if all cases are covered where an emptyMessage needs to contain the remaining text, but til now it worked fine. needs a lot of testing though! -- 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 post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/fd2711b2-6c97-4d7d-97a6-cecf6b9c3913%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

