Share your VB Project

February 6, 2009

Convert a child form

Filed under: Module — kohimaru @ 4:32 pm

‘Declaration

Private Declare Function GetMenuItemInfo Lib “user32″ Alias “GetMenuItemInfoA” (ByVal hMenu As Long, ByVal uItem As Long, ByVal fByPosition As Long, lpmii As MENUITEMINFO) As Long
Private Declare Function GetMenuItemCount Lib “user32″ (ByVal hMenu As Long) As Long
Private Declare Function GetSystemMenu Lib “user32″ (ByVal hwnd As Long, ByVal bRevert As Long) As Long
Private Declare Function RemoveMenu Lib “user32″ (ByVal hMenu As Long, ByVal nPosition As Long, ByVal wFlags As Long) As Long
‘ Menu flags
Private Const MF_BYPOSITION As Long = &H400
Private Const MF_REMOVE As Long = &H1000
Private Const MIIM_ID As Long = &H2
Private Const MIIM_TYPE As Long = &H10
Private Const MFT_STRING As Long = &H0
‘ Menu structure
Private Type MENUITEMINFO
cbSize As Long
fMask As Long
fType As Long
fState As Long
wID As Long
hSubMenu As Long
hbmpChecked As Long
hbmpUnchecked As Long
dwItemData As Long
dwTypeData As String
cch As Long
End Type

(more…)

Membuat Modul OnTop dengan VB 6.0

Filed under: Module — kohimaru @ 1:40 pm

 

‘1. buat modul dengan nama mdlOnTop
‘ketik pada modul

‘— begin —

Option Explicit
Const HWND_TOPMOST = -1
Const HWND_NOTOPMOST = -2
Const SWP_NOMOVE = &H2
Const SWP_NOSIZE = &H1
Const SWP_NOACTIVATE = &H10
Const SWP_SHOWWINDOW = &H40
Const TOPMOST_FLAGS = SWP_NOMOVE Or SWP_NOSIZE

(more…)

Theme: Rubric. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.