Script doesn't work after added in menu bar.
A premier mind-mapping software written in Java
Brought to you by:
christianfoltin,
danielpolansky
Hi,
I have a script that works fine when added to nodes via the Tools->Script Editor method. Following the method to add script into FM menu bar, explained by Foltin in "How to install a script as a menu item", while I did see the menu added, but the script didn't generate the expected result. In fact, how do I even know if the script has been run ?
To do this, save the script to a file and edit "ScriptingEngine.xml" inside the FreeMind script directory inside your installation.
You'll find a template for a script action that is commented out (ie. surrounded by ). Uncomment the template and fill out the following bold places:
-----------------------------------------------------------
By "save the script to a file", does that mean save the file as a groovy file, or what file ?
Last edit: Pang Wei San 2020-12-07
Hi, yes, save it as myfile.groovy or the like and set the ScriptLocation accordingly. HTH, Chris
Hi Christian,
While doing further testing on getting my script to the menu bar (the script basically selects the root node and changes all its children node text color to blue), it seemed the Tools -> Script Editor menu was missing, weird.
What's the reason this is happening ?
hi, can you supply the log file, please? BR, Chris
Hi Christian,
Yes, attached are the log files.
OK, found it. You have to use double backslash in the path:
C:\My Any\Me\...
HTH, Chris
Hi Chris,
Thanks ! It's working now. I could add the script to menu bar as well as running it and generating the expected outcome.
I have one question, the pop-up note box doesn't seem to be scrollable, my script populates each node with software documentation info into the note box, but some of the info cannot not be viewed as it overflows the note box and the note box is not scrollable. How to make the note box scrollable ?
Attached is a screen shot.
rgds
Pang
Hi,
isn't the long note editor better suited for long text attached to a node?
HTH, Chris
Hi Chris,
Are you refering to the "long Node" or "long Note" editor ?
If it's the note editor at the bottom half of the window, Yes, I think that also does the job. Previously I had seen problems where the pop up note window displayed the correct content, but the note editor didn't, I don't know why that happened, that's why I tried not to use the note editor to see what I inserted through the script, but it seems doing OK now.
Thanks for your prompt response, you have been very helpful.
rgds
Pang