У меня 64-битный офис.
Private Declare Function SetForegroundWindow Lib "user32" (ByVal hWnd As Long) As Long 'в начале модуля формы
не катит, ругается....
|
Ну а поиск кому?
#If VBA7 = 1 Then
Declare PtrSafe Function SetForegroundWindow Lib "user32" (ByVal hWnd As LongPtr) As Long
#Else
Private Declare Function SetForegroundWindow Lib "user32" (ByVal hWnd As Long) As Long
#End If