
4.9 Scripting 65
activeWave.addMarker(generic, "Marker "+i, "A comment for marker "+i);
//write some information about the new marker
var cursorTimeSecs = nextCursorPosition/activeWave.sampleRate();
logWindow.printInfo("created a new marker at " + cursorTimeSecs + " seconds");
}
Related topics
WaveLab Scripting Language
ECMAScript Reference
Scripting window (Audio File Workspace)
Scripting window (Audio Montage Workspace)
Control Window
4.9.1 WaveLab Scripting Language
WaveLab's scripting language varies slightly between Workspaces. This Help entry briefly
introduces you to the commands that are available in each Workspace and to those that are
global.
Global Commands
These are scripting commands that are available in all scripting contexts.
logWindow
Object representing the Log window, where you can output messages to. If the log window
is not open, all functions are ignored (as they are not visible anyway).
Functions
printInfo(messageString) - Outputs an informal message to the Log window. The mes-
sage argument must be typed as a String - i.e. between inverted commas.
Example:
logWindow.printInfo("start");
printWarning(messageString) - Outputs a warning message to the Log window.
printError(messageString) - Outputs an error message to the Log window.
clear() - Clears the log window.
Example:
logWindow.clear();
WaveLab 7
Comentarios a estos manuales