VB工程 百例97 是標題欄閃爍

2021-06-03 17:43:41 字數 520 閱讀 1741

option explicit

private sub timer1_timer()

flashwindow me.hwnd, true'呼叫flashwindow函式是窗體標題欄閃爍

beep'使計算機的揚聲器發出響聲

end sub

option explicit

public declare function flashwindow lib "user32" (byval hwnd as long, byval binvert as long) as long

'函式原型: declare function flashwindow lib "user32" alias "flashwindow" (byval hwnd as long, byval binvert as long) as long

'函式說明: 閃爍顯示指定視窗。這意味著視窗的標題和說明文字會發生變化,似乎從活動切換到非活動狀態、或反向切換。通常對不活動的視窗應用這個函式,引起使用者的注意

flashwindow :

VB工程 百例64游標位置

option explicit private sub command1 click txt1.text 歡迎來到廊坊師範學院 end sub private sub command2 click txt1.text end sub private sub command3 click endend...

VB工程 百例69 訊息框

option explicit private sub form click dim x as integer x msgbox 你單擊的是窗體,是嗎?35,詢問框 if x 6 then 若們四個box的函式的返回值是6 msgbox 你選擇了 是 按鈕 vbinformation,資訊框 彈出的...

VB工程 百例74 窗體變色

option explicit private sub form mousedown button as integer,shift as integer,x as single,y as single if button 2 then 若單擊滑鼠右鍵 popupmenu mnuformcolor ...