PDA

View Full Version : Create Drop-down menu in Word



neodjandre
06-17-2008, 06:54 AM
Hi,

I would like to create a drop-down menu in Word from where I can call my macros. Does anyone have any experience of how to do that?

thanks in advance
Andy

CreganTur
06-17-2008, 07:41 AM
Will this be for just one document, or do you want to have this available for every document you open?

neodjandre
06-17-2008, 07:45 AM
Hi,

I would like this to be available for all documents!

thanks for your help
andy

lucas
06-17-2008, 08:11 AM
Create a document with your menus created like this:
http://slucas.virtualave.net/Wink/CustomMenuItem.htm

Save the document with the menu's and macros as a template(.dot) and put it in your Word startup directory.

You can create the drop downs by selecting New Menu instead of macro's and then create each new menu item by selecting macro's and add them to the new menu.

neodjandre
06-17-2008, 08:17 AM
lucas, that's great.. However, is there a way to do it programatically via vba if possible?

Also can this menu not be distributed as an add-in like Microsoft EXCEL? .. or do I have to tell my colleagues to put the .dot file in their startup directory .. which i don't know where it would be!

lucas
06-17-2008, 08:20 AM
Why would you want to do it programatically?

It operates just like an addin in excel but you will have to manually put it in thier startup directory.....

Tools-Options-File locations tab.

lucas
06-17-2008, 08:21 AM
The only reason we do it programatically in Excel is because it does not have the userfriendly interface for menu's that Word has......so there is no need to do it programatically......

fumei
06-17-2008, 09:14 AM
"userfriendly interface for menu's that Word has"

I am...shocked!

lucas
06-17-2008, 09:40 AM
It is an oddity for Word but true is true....and it is true in this case. Word has many uses (and I use it more now than ever) that Excel is not great at. It remains a different animal in my mind......probably because I learned Excel first......

fumei
06-17-2008, 10:02 AM
"and I use it more now than ever)"

Excellent. That means (I think) that you are using Word for what it is good at, and Excel for what it is good at.

All is right in the world.

What I find interesting is how the two teams (the Excel team and the Word team) seem - at times - to live in utterly different worlds. I mean, yes, they are different applications, with different purposes and processes.

Yet conceptually there are times when the Object models are so totally foreign and incoherent to each other, that I am amazed that they come from the same software company. Especially when they are supposedly so "integrated".

Your example is an very good one. WHY would not Excel have as much "user-friendly" menu interface as Word?

The answer? Because the Excel team does not fully talk with the Word team. Or so it seems to me.

lucas
06-17-2008, 10:11 AM
This is one area where the Excel team could learn something useful from the Word team. I agree, they seem to be developed by completely different groups with little cooperation.

Excel has made an attempt at this but it does not work reliably in Excel as it does in Word.

Yes Gerry, I have learned to appreciate many things that Word has to offer. I even have developed a few templates commercially since I started lurking and learning here......thanks for your contributions.

MOS MASTER
06-17-2008, 12:22 PM
"userfriendly interface for menu's that Word has"

I am...shocked!

At least Word has a great feature called CustomizationContext :rofl:


Yet conceptually there are times when the Object models are so totally foreign and incoherent to each other, that I am amazed that they come from the same software company. Especially when they are supposedly so "integrated".

Agreed but too nice! Not only Word & Excel have those differences that we cannot understand. It's the same for the whole Office-suite.

And it boggles the mind this could ever happen!

GregQik
07-12-2008, 12:23 AM
Both Excel and Word use the same commandbar structure and the code to produce menu structures ( or toolbars) works the same in both 2003 versions.

Once debugged, building menus on the fly is both quick and painless.

Excel is a little different on exiting though.