Nick,
Excellent! Thanks for that. It works perfectly.
So, how does one know when to use <commands> and when to use <menu> or <button>? SheetMoveOrCopy is listed as a button in the ExcelRibbonControls.xlsx worksheet from Microsoft. There must be some logic to this, and you seem to have broken the code (thankfully).
Would I use <button idMso="SheetMoveOrCopy" enabled="false"/> to just disable the button for that command that can be added to the QAT?
I noticed that disabling SheetMoveOrCopy disables it on the sheet tabs and the QAT (if it was added there) as well as the Format menu. That is really great.
BTW, this all came up because I give exams using Excel in my Financial Modeling class. For many years, I've used a bunch of VBA to keep students from doing certain things during the exam (like doing a SaveAs). It seems that I can now do some of that in the interface. Do you know where I can find a list of what qualifies as a <command> that can be disabled using the RibbonX code? I don't recall seeing anything like this on MSDN in the articles on modifying the ribbon.
One thing that I really dislike about the new file formats is that saving as .xlsx will just strip out any VBA. That easily defeats all of my protection tools. That's why I needed to disable all of the SaveAs types other than .xlsm.
Tim