Hi Tamir
for (1), the only thing Word provides are Comments. You can "Add" a Comment
for a RANGE object. You'll probably also want to turn off "balloons" display
if this is Word 2002 or later. In order to see this in the UI (and record a
macro in order to get the basic syntax), comments are inserted over
Insert/References/Comments. To turn off the "balloons", Tools/Options/Track
Changes
(2) The right-click menus are part of the CommandBars collection
(msoBarPopup type). No problem removing/adding CommandBar buttons to those.
As always, when working with Word's CommandBars, you want to consciously set
the CustomizationContext and, if the changes aren't for the single documents,
you want to be sure to return these CommandBars to their original state when
your Addin is finished.
The shortcut menus in Word can be accessed through Tools/Customize/Toolbars.
You'll get a toolbar with three entries, under these all the different
commandbars are listed. Depending on the context in which the mouse/cursor
finds itself, a different shortcut menu is shown, so it's possible you may
have to change more than one menu. To access a menu via the object model,
then:
CommandBars("NameAsYouSeeInTheList")
If you prefer to roll your own, rather than modify the built-in ones, you
need to sink the WindowBeforeRightClick event. That provides an argument to
cancel the default action, and you can display your own "Popup" commandbar,
instead.
--
-- Cindy
:
Hi Cindy Meister,
Maybe you will have an idea, ...
Basically I wish to add tips to some words in the document.
I want these tips to be shown when the mouse is placed on a word.
Further, I would like to add an item to the right-click menu of the mouse
(and sink it).
Is it possible to do without getting into troubles???
:
Hi Tamir
The Word object model exposes no mouse events. The closest you could manage
would be to use the Windows API, but I understand it's a real PAIN, if it
works at all.
--
-- Cindy
:
Hi all,
I have an addIn which I wrote for ms-word and i wish to handle mouse events
in my addin.
In my addin i use a class handler for each component that I wish to sink.
but here i dont know what to sink, I dont have (dont know) the GUID DIID__...
----
can someone help me with it?
Any piece of help will be appreciated.
Thanks in advanced
Tamir.