home *** CD-ROM | disk | FTP | other *** search
- ;HwndCtrl.ASM -- Function to return hWnd of Visual Basic Control
- ;Copyright (c) 1992 Jay Munro
- ;First published in PC Magazine June 16, 1992
-
- ;----------------------------------------------------------------------------
- ;ControlHwnd receives the name of a control (hCtl) and calls Visual Basics
- ;internal routine VBGetControlHwnd. The hWnd of that control is
- ;returned in AX.
- ;----------------------------------------------------------------------------
-
- .286P
- .Model Medium
-
- Include Labnotes.Inc ;Macros etc...
- Public ControlHwnd
-
- Extrn VBGetControlHwnd:Proc
-
- .Code
- ControlHwnd Proc Far ;Export
- ShortWinProlog ;DS is never used
- Push Word Ptr [BP+8] ;push hiword of hCtl
- Push Word Ptr [BP+6] ;push loword of hCtl
- Call VBGetControlHwnd ;call Visual Basic's API
- ShortWinEpilog
- Ret 4
- ControlHwnd EndP
-
- End
-