Showing posts with label Tips and triks. Show all posts
Showing posts with label Tips and triks. Show all posts

Wednesday, March 31, 2004

Tips and Trik in Window

Change Dialog/Window Icon runtime
WM_SETICON
Set hIcon = ExtractIconA( GetWindowLongA( hWndForm, GWL_HINSTANCE ),
"USER32.DLL", 2 )
Call SalSendMsg( hWndForm, WM_SETICON, ICON_SMALL, hIcon )

Mencari suatu windows di open atau tidak
If SalFindWindow( hWndMDI, 'fwEmployee') != hWndNULL

Multi line text pada button
On WM_NCCREATE
Call SetWindowLongA( hWndItem, GWL_STYLE,
GetWindowLongA( hWndItem, GWL_STYLE ) | BS_MULTILINE )

atau dengan:
Call VisWinSetStyle( hWndItem, BS_MULTILINE, TRUE )