I am trying to use Delphi (D6 or D7) to control Excel (2000 or XP). I can use TExcelApplication, TExcelWorkbook etc to read & write data & formulae to/from cells AOK, but I'm having a problem controlling the menus.
What I would like to do for example is to disable the File:Print menu item. When I try to set Commandbars.Item .........Enabled := False it tells me "Cannot assign to a read-only property. This should be a simple thing to do - or am I missing something ?
Can someone provide me a simple code sample on how to do this please ?