ウィンドウの位置・サイズを変更
Declare Function MoveWindow Lib "user32.dll" _
(ByVal hWnd As Long, ByVal x As Long, _
ByVal y As Long, ByVal nWidth As Long, _
ByVal nHeight As Long, ByVal bRepaint As Long) As Long
Declare Function MoveWindow Lib "user32.dll" _
(ByVal hWnd As Integer, ByVal x As Integer, _
ByVal y As Integer, ByVal nWidth As Integer, _
ByVal nHeight As Integer, ByVal bRepaint As Integer) As Integer
BOOL MoveWindow(
HWND hWnd,
int X,
int Y,
int nWidth,
int nHeight,
BOOL bRepaint
);
引数
hWnd
ウィンドウのハンドルx
移動した後の左上隅のX座標y
同、Y座標nWidth
変更後の幅nHeight
同、高さbRepaint
アプリケーションが再描画するとき0戻り値
自動的に再描画するとき1
正常終了のとき 0以外備考
エラーのとき 0
子ウィンドウのときは
親ウィンドウのクライアント座標で設定する。
Visual BasicのMoveメソッドと同じ働きをする。