LordJashin Posted October 13, 2012 Share Posted October 13, 2012 All the WriteLn's have now been changed to the new OSI_WriteAndLog procedure. New variables: OSI_Log : TStrArray (OSI_WriteAndLog, WriteLn's the text put into it, then adds it to this array) OSI_AutoLog : Boolean (Enable autologging for your script. Logs will be saved to LogsPath) OSI_AutoLogName : string (Name your autolog, good just in case you are running multiple scripts and don't want things to be mixed up or overwritten) IsOSISetup : Boolean (Will be set to true, if you run SetupOSI) Most of OSI now is in try..except..finally blocks, and overall runs a lot better. New Logging Functions in Divi\Misc\Logging.scar: procedure OSI_WriteAndLog(s: string); procedure OSI_ClearLog; function OSI_SaveLog(Path: string): Boolean; New Client Functions in Divi\Client.scar: function FindWindowEx(Title: string, CaseSensitive, PartialMatch: Boolean): HWND; function SetClientBox(Client: TSCARClient; cX1, cY1, cX2, cY2: Integer): Boolean; procedure SCARSetCaption(Title: string); procedure SCARMoveToTray; procedure SCARMinimize; procedure SCARMaximize; procedure SCARHide; procedure SCARShow; procedure SCARSetEnabled(Enabled: Boolean); function SCARHandle: HWND; All the SCAR functions are utilizing the GetSelf object. SetClientBox will set a clients ImageArea and Input Area to cX1, etc. FindWindowEx is like the old FindWindowTitlePart. It will Find a window by its title, casesensitivity, and partialMatch of the title. It returns the Handle of the window if it finds one. So you can do now: ActivateWindow(FindWindowEx('Notepad', false, True)); Enjoy Quote Link to comment Share on other sites More sharing options...