views:

25

answers:

2

I'm trying to get to grips with customising a Ribbon Bar for a converted A2003 app. I'm trying to work out how to use my own custom images on button controls in the ribbon. Can anyone point me to an example for Access 2007 that can do this pls?

+1  A: 

Please check this MSDN article (Adding Custom Dynamic Menus to the Office Fluent User Interface) and see if it helps you. Furthermore I would point you to the specifying image resource MSDN article, because you need different sized images for different sized buttons - read the bottom of my post to make it easier on you.

I believe there was also custom images within the official MS example on ribbon extensibility with Access 2007 - I hope this example is sufficient, it helped me a great lot.

My personal favorite is just using a graphical UI editor, such as the "Custom UI Editor Tool". With it you just click a button to insert an image and it works (as explained in this tutorial). Even better as the Custom UI Editor is the IDBE Ribbon Creatror - my personal tool of choice. A shareware version is available from the website.

moontear
Thank you. I found that the 'Custom UI Editor' doesn't work with MS Access. I bought Gunter Avenius's IDBE Ribbon Creator, which although very useful, didn't manage to import into Access.
maxhugen
I did user another of Gunter's tools, the 'IconInRibbon' free db, (see his 'Downloads' section) which successfully imported my custom images into a table, and used VBA to get and use the images in the Ribbon. Hooray!
maxhugen
Weird issues you are having with the IDBE Ribbon Creator, for me it works flawlessly - maybe Gunter can help you out? Besides that: Great, that you got it to work!
moontear
+1  A: 

I have a working example class object you can use that makes this a good deal less code.

http://www.members.shaw.ca/albertKallal/Ribbon/ribbon.htm

The above lets you use a very much like previous style code approach. So, to set a picture for a ribbon, you can go:

meRib("Button1").Picture = "HappyFace.png"

The same download has a working form in which some images in the ribbon change from choices made on the form.

Albert D. Kallal
Thanks Albert, your VBA class looks very interesting! I going to study that carefully, as I also have runtime issues of security access such as you described.
maxhugen