Sì, e' utilizzabile, ovviamente per indirizzo (ByRef).
Dai un'occhiata a questo codice
codice:Private Type RECT Left As Long Top As Long Right As Long Bottom As Long End Type Private Declare Function GetWindowRect Lib "user32" (ByVal hwnd As Long, ByRef lpRect As RECT) As Long Private Declare Function GetDesktopWindow Lib "user32" () As Long Private Declare Function GetWindowDC Lib "user32" (ByVal hwnd As Long) As Long Dim DskHwnd As Long Dim DskRect As RECT Dim DskHdc As Long Dim rc As Long DskHwnd = GetDesktopWindow() DskHdc = GetWindowDC(DskHwnd) rc = GetWindowRect(DskHwnd, DskRect) Debug.Print DskRect.Left, DskRect.Top, DskRect.Right, DskRect.Bottom

Rispondi quotando