Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to use it
Message
 
To
15/02/2005 04:10:26
Ashish Patel
Hindustan Petroleum
Mumbai, India
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
Environment versions
Visual FoxPro:
VFP 6
OS:
Windows 2000
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00986907
Message ID:
00986924
Views:
50
May be something like this:

make a method in the form Named i.e. Animate
at LAST row in Init method of the form put
this.Animate()


**** Here is the code of ANIMATE Method
#define IDANI_OPEN    1
#define IDANI_CLOSE   2
#define IDANI_CAPTION 3
*!*    Private Type RECT
*!*        Left As Long
*!*        Top As Long
*!*        Right As Long
*!*        Bottom As Long
*!*    End Type

DECLARE LONG FindWindowA IN WIN32API STRING class, STRING title
DECLARE INTEGER SetRect IN WIN32API;
                           STRING @lpRect,;
                           INTEGER X1,;
                           INTEGER Y1,;
                           INTEGER X2,;
                           INTEGER Y2
DECLARE INTEGER DrawAnimatedRects IN WIN32API;
                           INTEGER hWnd,;
                           INTEGER idAni,;
                           STRING  lprcFrom,;
                           STRING  lprcTo
STORE SPACE(16) TO rSource, rDest
STORE 0 TO ScreenWidth, ScreenHeight

** Get _Screen hWnd
lhWnd = FindWindowA(0, _Screen.Caption)

ScreenWidth  = _Screen.Width
ScreenHeight = _Screen.Height

toCenterT     = INT((_Screen.Width-this.Width)/2)
toCenterL     = INT((_Screen.Height-this.Height)/2)

SetRect(@rSource, ScreenWidth, ScreenHeight, ScreenWidth, ScreenHeight)
SetRect(@rDest, toCenterT, toCenterL, toCenterT+this.Width , toCenterL+this.Height)
DrawAnimatedRects(lhWnd, BITOR(IDANI_CLOSE,IDANI_CAPTION), rSource, rDest)
this.Move(toCenterT,toCenterL,this.Width,this.Height)
But keep in mind it is NOT tested.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform