Visual Basic에서 TaskBar 사이즈 얻어오기

Public Declare Function FindWindow Lib “user32” Alias “FindWindowA” (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Public Declare Function GetWindowRect Lib “user32” (ByVal hwnd As Long, lpRect As RECT) As Long
Public Type RECT
        Left As Long
        Top As Long
        Right As Long
        Bottom As Long
End Type

    Dim hTaskbar As Long
    Dim rTaskbar As RECT
    Dim sClass As String
    sClass = “Shell_TrayWnd”
    hTaskbar = FindWindow(sClass, “”)
    GetWindowRect hTaskbar, rTaskbar

답글 남기기