Microsoft KB Archive/134447

From BetaArchive Wiki
< Microsoft KB Archive
Revision as of 19:16, 12 August 2020 by X010 (talk | contribs) (X010 moved page Microsoft KB Archive/Q134447 to Microsoft KB Archive/134447 without leaving a redirect: Text replacement - "Microsoft KB Archive/Q" to "Microsoft KB Archive/")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

How to Hide the Desktop in Visual FoxPro

PSS ID Number: Q134447 Article last modified on 08-20-1995

3.00

WINDOWS

The information in this article applies to:
- Microsoft Visual FoxPro for Windows, version 3.0

SUMMARY

Using the FindWindow and ShowWindow API calls from within Windows, the main Visual FoxPro desktop can be hidden and recalled on demand. This article shows by example how to do it.

MORE INFORMATION

The following code demonstrates how to hide and display the main FoxPro desktop.

Sample Code


  • This function manipulates the main Visual FoxPro window.
  • This function may be called in the Load Event of a form that
  • has these properties: WindowType = Modal, AlwaysOnTop = True,
  • and DeskTop = True ************************************************************** #DEFINE W32sDLL “W32SCOMB.DLL” #DEFINE W32DLL “USER32.DLL” IF “3.5” $ OS() OR “Windows 4” $ OS() && cDLL = W32DLL ELSE cDLL = W32sDLL ENDIF

DECLARE integer FindWindow IN &cDLL integer, string DECLARE Integer ShowWindow IN &cDLL Integer, Integer

SW_MAXIMIZE = 3 SW_SHOWNORMAL = 1 SW_SHOWMINIMIZED = 2 SW_SHOWGONE = 0

NullPointer = 0 FoxHWND = FindWindow(NullPointer, _SCREEN.Caption)

  • Hide the Main Visual FoxPro Window FoxGone = ShowWindow(FoxHWND, SW_SHOWGONE)

=MessageBox(“Visual FoxPro Desktop is hidden…”)

FoxGone = ShowWindow(m.FoxHWND, SW_SHOWNORMAL)

Additional reference words: VFoxWin 3.00 Command window Hide Desktop KBCategory: kbprg kbcode KBSubcategory: FxprgUdwindow

=================================================================

Copyright Microsoft Corporation 1995.