SVP
J'ai besoin d'un code vba qui me permet de diminuer les dimension d'une fenêtre excel
Merci
Sub Macro1()
Application.WindowState = xlNormal
Application.Width = 308.25 ' dimensions à adapter selon besoin
Application.Height = 251.25 ' dimensions à adapter selon besoin
End Sub
Sub Initialiser()
'se lance par Ctrl+I
With Application
.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",true)" 'affiche le ruban
.DisplayFormulaBar = True
.WindowState = xlNormal
.Height = 600
.Width = 1000
.WindowState = xlMaximized
End With
End Sub
Sub Diminuer()
'se lance pat Ctrl+D
With Application
.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)" 'masque le ruban
.DisplayFormulaBar = False
.WindowState = xlNormal
.Height = 0.9 * .Height
.Width = 0.9 * .Width
End With
End Sub