Get Commands: Difference between revisions
From Macros Wiki
Jump to navigationJump to search
New page: ! get the list of macro commands<br> ! ------------------------------<br> <br> global iver1, iver2, iver3, inotes<br> <br> ioption = 0 ! all commands<br> iver1 = gibbscam_version_1<b... |
No edit summary |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
! get the list of macro commands | {| | ||
! ------------------------------ | |- | ||
|! get the list of macro commands | |||
global iver1, iver2, iver3, inotes | |- | ||
|! ------------------------------ | |||
ioption = 0 | |- | ||
iver1 = gibbscam_version_1 | | | ||
iver2 = gibbscam_version_2 | |- | ||
iver3 = gibbscam_version_3 | |global iver1, iver2, iver3, inotes | ||
inotes = 0 | |- | ||
| | |||
dialog "[[GetCommands.dlg]]" | |- | ||
|ioption = 0 || ! all commands | |||
! create a file open dialog | |- | ||
! ------------------------- | |iver1 = gibbscam_version_1 | ||
|- | |||
|iver2 = gibbscam_version_2 | |||
file_dialog_extension "Text files (*.txt)", "txt" | |- | ||
file_dialog_extension "All files (*.*)", "*" | |iver3 = gibbscam_version_3 | ||
file_dialog_show save, f$ | |- | ||
|inotes = 0 | |||
! get the command list | |- | ||
! -------------------- | | | ||
|- | |||
all_commands = 1 | |dialog "[[GetCommands.dlg]]" | ||
output_notes = 1 | |- | ||
| | |||
if ioption = 1 then all_commands = 0 ! new commands only | |- | ||
if inotes = 1 then output_notes = 2 ! notes are required | |! create a file open dialog | ||
|- | |||
if all_commands = 0 then get_commands f$, output_notes, iver1, iver2, iver3 | |! ------------------------- | ||
if all_commands = 1 then get_commands f$, output_notes | |- | ||
| | |||
!debug gibbscam_version_1, gibbscam_version_2, gibbscam_version_3, plugin_version_1, plugin_version_2, plugin_version_3 | |- | ||
|file_dialog_new "Select output filename" | |||
message "Finished: Output file = %f$" | |- | ||
|file_dialog_extension "Text files (*.txt)", "txt" | |||
|- | |||
|file_dialog_extension "All files (*.*)", "*" | |||
|- | |||
|file_dialog_show save, f$ | |||
|- | |||
| | |||
|- | |||
|! get the command list | |||
|- | |||
|! -------------------- | |||
|- | |||
| | |||
|- | |||
|all_commands = 1 | |||
|- | |||
|output_notes = 1 | |||
|- | |||
| | |||
|- | |||
|if ioption = 1 then all_commands = 0 ||! new commands only | |||
|- | |||
|if inotes = 1 then output_notes = 2 ||! notes are required | |||
|- | |||
| | |||
|- | |||
|if all_commands = 0 then get_commands f$, output_notes, iver1, iver2, iver3 | |||
|- | |||
|if all_commands = 1 then get_commands f$, output_notes | |||
|- | |||
| | |||
|- | |||
|!debug gibbscam_version_1, gibbscam_version_2, gibbscam_version_3, plugin_version_1, plugin_version_2, plugin_version_3 | |||
|- | |||
| | |||
|- | |||
|message "Finished: Output file = %f$" | |||
|} | |||
Latest revision as of 15:11, 29 July 2010
| ! get the list of macro commands | |
| ! ------------------------------ | |
| global iver1, iver2, iver3, inotes | |
| ioption = 0 | ! all commands |
| iver1 = gibbscam_version_1 | |
| iver2 = gibbscam_version_2 | |
| iver3 = gibbscam_version_3 | |
| inotes = 0 | |
| dialog "GetCommands.dlg" | |
| ! create a file open dialog | |
| ! ------------------------- | |
| file_dialog_new "Select output filename" | |
| file_dialog_extension "Text files (*.txt)", "txt" | |
| file_dialog_extension "All files (*.*)", "*" | |
| file_dialog_show save, f$ | |
| ! get the command list | |
| ! -------------------- | |
| all_commands = 1 | |
| output_notes = 1 | |
| if ioption = 1 then all_commands = 0 | ! new commands only |
| if inotes = 1 then output_notes = 2 | ! notes are required |
| if all_commands = 0 then get_commands f$, output_notes, iver1, iver2, iver3 | |
| if all_commands = 1 then get_commands f$, output_notes | |
| !debug gibbscam_version_1, gibbscam_version_2, gibbscam_version_3, plugin_version_1, plugin_version_2, plugin_version_3 | |
| message "Finished: Output file = %f$" |