#DEFINE SW_MAXIMIZE 3 LOCAL llRunning, ; lcCaption, ; lnHWnd llRunning = .F. * Temporarily rename the caption of * the screen, we don't want to find * ourselves. lcCaption = _SCREEN.Caption _SCREEN.Caption = [_] + lcCaption lnHWnd = FindWin(lcCaption) IF lnHWnd <> 0 DECLARE INTEGER ShowWindow in user32 ; INTEGER hwnd, ; INTEGER nCmdShow ShowWindow(lnHWnd, SW_MAXIMIZE) llRunning = .T. ENDIF _SCREEN.Caption = lcCaption RETURN llRunningI've also modified the Setup.PRG and added the code:
*--------------------------------------------------- *-- Check to see if the app. is already running. If *-- it is, and it's only meant to be run once, let's *-- exit. The running app. will automatically be *-- brought to the front, maximized. *--------------------------------------------------- * PCM - 8/9/2002 IF goApp.lOnlyOneInstance IF goApp.IsRunning() QUIT ENDIF ENDIFThis code is put right after creating goApp (after the RELEASE code and before the *--- Support for Steven Black's INTL) line.