hi

i have the following code which is supposed to minimize the ribbon when the workbook is opened

dim iHeight as integer

 iHeight = Application.CommandBars("ribbon").Height 
    If iHeight > 100 Then
        Application.SendKeys ("^{F1}")
    End If
this works on one workbook but not another! on the second workbook, the code opens excel help, which you
can get by just pressing F1, but the code is for "Ctrl + F1". What could be the issue here?

cheers


i even tried Application.CommandBars.Item("Ribbon").Height but same result