Xlls and the ribbon UI
Tuesday, 2nd October, 2007I thought I would do a quick post on the new features in the Excel 2007 xll SDK relating to the ribbon UI. So here is the summary:
_
_
_
And here is the detail:
_
_
_
Thats right, the 2007 xll dev kit and the Excel 2007 C API contain zero features that interact with the ribbon (unless I missed something??). And lets not forget xlls are the recommended add-in technology of choice for Excel 2007. Of course if you do any toolbar/menu interaction the ribbon will hijack it in the normal way. But there is no way to add tabs or anything, everything is going to get buried in the (second class) add-in tab/bin.
A couple of new constants I was hoping for:
xlcKillRibbon (optional - forever?)
xlcRevertToCommandBars
Maybe in the Office 14 SDK??
I thought the kit actually included an .xlam with the UI code in. I wouldn’t blame them for that, VBA is great for UI
- its quick and easy to write
- UI stuff doesn’t need to super fast
- No real intellectual property issues in creating a few buttons (is there a new inconsistent User Experience Astronaut term for button? ’switch’?’ or ‘кнопки’?)
But having ratched through it, I can’t just see the Ribbon manipulation stuff at all. And because the UEA’s have moffed up all the useful commands I have no idea how to find whats going on. It looks like the xll fires stuff into the ‘generic’ menu (as previously) which then ends up hidden in the add-ins ribbon tab. The .xlsm stuff just seems to contain a bunch of XLM - yay! Its great to see MS have not lost faith in this oldie but goldie technology. (reports of its death are premature as they say)
So if your xll based solution is to integrate natively in 2007 and its silly UI, it will need to be a multiple file thing. And possibly requiring registry access, and/or .net framework. Thats a bit crap really, a single file distribution is a much easier deployment story. Being a Ribbon refusnik I have no idea how to structure such a solution, and no immediate plans to find out.
I’m sure its down to a resource issue rather than a lack of love for the ribbon in the Excel team.
You can get to the ribbon using ATL as per this post. But that probably needs registration unlike xlls.
And its not quite as straightforward as xlfAddToolBar!
cheers
Simon

