Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
FoxPro 2.6 Windows running Shellexecute
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00179403
Message ID:
00179546
Views:
22
>George,
>
>I downloaded your is_run program and it does indeed find the window running, but I'm at a loss as to how to call showwind. I guess I need some help on converting the following declaration into something that can be used with foxtools.fll:
>DECLARE Integer ShowWindow in Win32API integer iWinHndl, integer iCond
>
>I appreciate your help on this. It's not just to get this one little annoyance taken care of, it's become one of those things you just have to resolve!
>
Hi John,

No problem, glad to be of help.

Below I listed the defined constants for the ShowWindow API call, and examples in both FPW and VFP. The function returns a logical value (which you can't define in VFP). Non-zero will equal true.
* nCmdShow values
#define SW_HIDE             0
#define SW_SHOWNORMAL       1
#define SW_NORMAL           1
#define SW_SHOWMINIMIZED    2
#define SW_SHOWMAXIMIZED    3
#define SW_MAXIMIZE         3
#define SW_SHOWNOACTIVATE   4
#define SW_SHOW             5
#define SW_MINIMIZE         6
#define SW_SHOWMINNOACTIVE  7
#define SW_SHOWNA           8
#define SW_RESTORE          9
#define SW_SHOWDEFAULT      10
#define SW_MAX              10

* In VFP

DECLARE SHORT ShowWindow IN Win32API;
  INTEGER hwnd, INTEGER nCmdShow
llresult = (ShowWindow(hWnd, nCmdShow) # 0)

* In FPW

m.showwind = RegFN("ShowWindow", "II", "I")
m.result = (CallFN(m.showwind, m.hWnd, m.nCmdShow) # 0)
hth,
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform