Is there any event to track cursor movement in word?
I need to detect the cursor position and depending on that i need to toggle some buttons on Ribbon. How can i track the movement of cursor with mouse or keyboard events?. I am developing my addin in C# for MS Word 2010.
The only thing Word provides is the WindowSelectionChange event. This won't trigger when the user types, but it will when the arrow keys, backspace, or the mouse is used to change the cursor location. It will also trigger when the user enters or leaves cells
in a table, things like that.
If you need more than that, you'll have to work with the Windows API.
Cindy Meister, VSTO/Word MVP
Marked as answer byBessie ZhaoTuesday, February 08, 2011 9:29 AM