JavaScript Editor js editor     Web development 

Main Page

Returns the WHANDLE of the active window.

WHANDLE _WOnTop(void any)
void any;                     /* Pointer. */


Normally, keystrokes belong to the active window. Handler routines need to act appropriately.

For more information on how to create an API library and integrate it with Visual FoxPro, see Accessing the Visual FoxPro API.


The following example displays position information about the active window.

Visual FoxPro Code

В Copy Code

C Code

В Copy Code
#include <pro_ext.h>

void putLong(long n, int width)
   Value val;

   val.ev_type = 'I';
   val.ev_long = n;
   val.ev_width = width;

void FAR Example(ParamBlk FAR *parm)
   WHANDLE wh = _WOnTop();

   _PutStr("\ntop   ="); putLong(_WTop(wh), 5);
   _PutStr("\nleft ="); putLong(_WLeft(wh), 5);
   _PutStr("\nbottom ="); putLong(_WBottom(wh), 5);
   _PutStr("\nright  ="); putLong(_WRight(wh), 5);

FoxInfo myFoxInfo[] = {
   {"WPOSITION", Example, 0, ""},
FoxTable _FoxTable = {
   (FoxTable FAR *) 0, sizeof(myFoxInfo)/sizeof(FoxInfo), myFoxInfo

See Also

JavaScript Editor js editor     Web development