VBA help

M

Maxi

Can one particular line in MS Word document be highlighted by a color
depending on where the mouse pointer is with the help of a vba?
(Mouseover)

Maxi
 
J

Jonathan West

Need more information.

1. What will the mouse be moving over when you want the line to be
highlighted?

2. How will the line to be highlighted be identified?

--
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Keep your VBA code safe, sign the ClassicVB petition www.classicvb.org
 
J

Jezebel

Not easily. Word VBA does not have any way to detect mouse movements. Word
itself obviously does (eg for Hyperlinks); but the information is not passed
on to VBA.
 
M

Maxi

1. What will the mouse be moving over when you want the line to be
highlighted?
Ans: Mouse can move anywhere in the document

2. How will the line to be highlighted be identified?
If the mouse is in the middle of the document, the middle line should
be highlighted by a background color

But if Jezebel says that Word VBA does not detect mouse movement, then
I guess it will not work.
 
J

Jonathan West

Maxi said:
1. What will the mouse be moving over when you want the line to be
highlighted?
Ans: Mouse can move anywhere in the document

2. How will the line to be highlighted be identified?
If the mouse is in the middle of the document, the middle line should
be highlighted by a background color

But if Jezebel says that Word VBA does not detect mouse movement, then
I guess it will not work.

I can confirm that Word cannot do what you are asking for. I was just
wanting to be clear on exactly what you wanted before saying that.


--
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Keep your VBA code safe, sign the ClassicVB petition www.classicvb.org
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top