Hi =?Utf-8?B?QXNoaXNoX0phaXB1cg==?=,
I have to write an Word Add-in. What I want is same functionality by which I
can write macros in .net as we can write with VBA and add these macros to
Toolbars buttons and menu item by simple drag and drop at the time of
Template creation.
There's no way you can assign "macros" written in a COM Addin (whether written
with VB.NET or classic VB6) to toolbar buttons via the user interface
(drag-and-drop from the Customize/Commands dialog box). The Word UI exposes
only public procedures in an opened/loaded VBA project, requiring no
parameters, in modules not marked with Option Private.
You'd have to create the toolbars and buttons in your Addin code. You should
find sample code for this on the msdn website, in the area dealing with
Office/Word.
Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org
This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail