Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Programming POS
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00352617
Message ID:
00352721
Views:
11
>Hi:
>I´m beginning to programming a P.O.S. and I want to know if there
>is a way to hide the windows taskbar.
>
>TIA.

Try the following:
lparameters tlShowWindowsTaskBar
declare integer FindWindow in user32.dll string, integer
declare ShowWindow in user32.dll integer, integer
lnHandleTaskBar = FindWindow("Shell_TrayWnd", 0)

if tlShowWindowsTaskBar
  ShowWindow(lnHandleTaskBar, 1) && Show task bar

  * Bring this application back to the foreground
  DECLARE INTEGER SetForegroundWindow IN win32api INTEGER

  *-------------------------------------------------------------------------
  * If the FOXTOOLS.FLL library is not already open, load it because we need
  * to access the MainHWnd() function to force the application to the fore-
  * ground after running the other programs.
  *-------------------------------------------------------------------------
  set library to foxtools additive
  * MainHWnd() returns the window handle (HWND) of the main Visual FoxPro window
  SetForegroundWindow(MainHWnd())
else
  ShowWindow(lnHandleTaskBar, 0) && Hide task bar
endif
The reasons for the extra code at the the end is because making the Task Bar disappear makes your application lose system focus. This brings it to the fore front again.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform