230 | Page
Ch a p t e r 1 8 – S c r i p t s M o d u l e
Copyright GetData Forensics Pty Ltd 2010 - 2015, All rights reserved.
ToolBar.AddButton('UltraEdit', 'C:\Program Files (x86)\IDM Computer
Solutions\UltraEdit\Uedit32.exe', '', -1, 64, 64, BTNS_SHOWCAPTION); //adds
and names the button
You can see that the first line creates the button group, and the next three lines point
to different types of HEX editors that may be installed on your system. Remember that
if the file does not exist, the code will be ignored and the button not added (Note that
because we run this as a default menu button we need to include two options for
͚Ultra Edit͛ to cover both the 32 and 64 bit version installation path).
To add a link to your own program, make a copy of one of these lines and then edit it.
Change the name of the button, put and put in the correct path on your machine.
Once you have edited the script, press the save button in the Scrip Editor window to
save you changes.
Running Your Script
A script is run in single thread mode by pressing the green play button
, or in multi
thread mode by pressing the green fast forward button in in the Script Editor toolbar.
However, running a button group script here is not going to work, because it needs to
know the parameter for the module where you want the button to appear (remember
this information is passed to the script at startup by the line in startup.pas).
You could close and restart Forensic Explorer to show the button. Or, in order to test
the script, we can do this in the scripts module by using the ͞Parameter͟ box in the
If you type in ͞File System͟ (use the quotes when a space is located in the module
name) in the parameters box and then run the script, the button will appear in the File
System module. If you type in Scripts, the button will appear in the Scripts module. If
there is an error in the script the messages will be displayed in the messages window
at the bottom of the Scripts module.
If you want to remove a button group without restarting, run the ͞Toolbar - Delete
utton Group Form.pas͟ in the Quick Reference folder.
You can then of course start experimenting. You can create your own script in
͞Scripts\Toolbar\My Custom utton Group.pas͟, fill it with your own buttons, and call
it using the startup.pas script so it is there each time you start the program. If you are
feeling brave, you can edit the Toolbar Manager.pas so that you can open and close it
on the fly.