Important: The information in this document is obsolete and should not be used for new development.
OSAStopRecording
You can use theOSAStopRecordingfunction to turn off Apple event recording.
FUNCTION OSAStopRecording(scriptingComponent: ComponentInstance; compiledScriptID: OSAID): OSAError;
scriptingComponent
A component instance created by a prior call to the Component Manager functionOpenDefaultComponentorOpenComponent(see page 10-4).compiledScriptID- A script ID for the compiled script into which Apple events are being recorded.
DESCRIPTION
TheOSAStopRecordingfunction turns off recording. If the script is not currently open in a script editor window, thecompiledScriptToModifyIDparameter supplied toOSAStartRecordingis then augmented to contain the newly recorded statements. If the script is currently open in a script editor window, the script data that corresponds to thecompiledScriptToModifyIDparameter supplied toOSAStartRecordingis updated continuously until the client application callsOSAStopRecording.If the compiled script identified by the script ID in the
compiledScriptIDparameter is not being recorded into or recording is not currently on,OSAStopRecordingreturnsnoErr.RESULT CODES
noErr 0 No error errOSASystemError -1750 General scripting system error errOSAInvalidID -1751 Invalid script ID badComponentInstance $80008001 Invalid component instance