Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Make form without titlebar movable
Message
 
To
27/11/2001 06:14:33
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00586200
Message ID:
00586265
Views:
16
>is there a simple way to make a form without titlebar movable ??
Ernst,

With following you can click anywhere on the form to move it. There was a discussion on www.foxite.com forum, message "A little help please..." as of November 19, 2001. Among others there are two ideas I would you point to:

1. drCipher' solution for VFP7:
Place this in the init of the form

Declare ReleaseCapture in "user32"
Declare long SendMessage in "user32" long hwnd, long wMsg, long wParam, long lParam

Place this in the MouseDown of the form

if nButton = 1 && probably only want to move the form when the left mouse button is down.
ReleaseCapture()
SendMessage(this.hwnd, 0x112, 0xF012, 0x0)
endif

2. For VFP6 you should add this to have a window handle:
SET LIBRARY TO foxtools.fll addi
lcCaption = thisform.caption
thisform.caption = SYS(3)
thisform.addproperty(hwnd, _WhTohWnd(_WFindTitl(thisform.caption)))
thisform.caption = lcCaption

Best Wishes
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform