1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
Private Declare Function GetWindowLongA Lib "User32" _
(ByVal hwnd As Long, ByVal nIndex As Long) As Long
Private Declare Function SetWindowLongA Lib "User32" _
(ByVal hwnd As Long, ByVal nIndex As Long, _
ByVal dwNewLong As Long) As Long
Private Declare Function FindWindowA Lib "User32" _
(ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Function user()
hwnd = FindWindowA(vbNullString, Me.Caption)
exlong = GetWindowLongA(hwnd, -16)
If exlong And &H880000 Then SetWindowLongA hwnd, -16, exlong And &HFF77FFFF
zfactor = 100 * CInt(Application.Width / Me.Width)
If zfactor > 400 Then zfactor = 400
Me.Width = Application.Width
Me.Height = Application.Height
Me.Zoom = zfactor
End Function
Sub user_ss_croix()
Dim hwnd As Long
hwnd = FindWindowA("Thunder" & IIf(Application.Version Like "8*", _
"X", "D") & "Frame", Me.Caption)
SetWindowLongA hwnd, -16, GetWindowLongA(hwnd, -16) And &HFFF7FFFF
End Sub |
Partager