SetWindowPOS is the function that completes the setting window location and status (POS = position). The source code is as follows:
Option expedition
Private Declare Function SetWindowPos Lib "User32" (Byval HwndInsertAfter As Long, Byval X As Long, Byval Y As Long, Byval Cy As Long, Byval WFLAGS As Long AS Long
PRIVATE CONST HWND_TOPMOST & = -1
'Place the window at the top of the list and located in front of any top window
PRIVATE CONST SWP_NOSIZE & = & H1
'Keep window size
Private const swP_nomove & = & h2
'Keep window position
Private sub flow_load ()
Setwindowpos me.hwnd, hwnd_topmost, 0, 0, 0, 0, swp_nomove or swp_nosize
'Set the window to always in the forefront
End Sub