ActivateFirstInstance
procedure OgFirst.ActivateFirstInstance;  {32-bit version}
procedure OgFirst.ActivateFirstInstance(const MainWindowCaption, MainWindowClass : string);  {16-bit version}

TurboPack OnGuard FMX

ActivateFirstInstance

procedure OgFirst.ActivateFirstInstance;  {32-bit version}

procedure OgFirst.ActivateFirstInstance(const MainWindowCaption, MainWindowClass : string);  {16-bit version}

Navigation:  »No topics above this level«

ActivateFirstInstance

procedure OgFirst.ActivateFirstInstance;  {32-bit version}

procedure OgFirst.ActivateFirstInstance(const MainWindowCaption, MainWindowClass : string);  {16-bit version}

Return to chapter overview

 

_bm1ActivateFirstInstance locates an application’s main window and then makes it the active window.

ActivateFirstInstance forces the window with the specified caption and class to the top of the z-Order and gives it the focus. This method is normally called after detecting that a second instance of the application was executed and subsequently halted. Calling ActivateFirstInstance gives the appearance that running the application a second time succeeded.

The 32-bit version of ActivateFirstInstance does not take any parameters and automatically locates the application’s main window. The 16-bit version of this routine requires that the class name and caption of the main form be passed as arguments.