Results 1 to 2 of 2

Thread: VBA:Word97: Help with screen coordinates

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2005
    Posts
    1

    Unhappy VBA:Word97: Help with screen coordinates

    Hi

    I'm trying to get the screen coordinates of selected words in a Microsoft Word 97 document so that I can display a small dialog box right under each selected word for spelling purposes. In Word 2000 and above that was easy because I could use the GetPoint function to get these coordinates, but I can't use it in Word'97. So far, I can get the coordinates of each selection relative to the page by using the Range.Information function, but I can't seem to be able to convert those to screen coordintates. I used the ClientToScreen api to do it by supplying the Word handle but it doesn't work right (which makes sense since the page's position in the window depends on the scrolling and zoom factor).

    So, if anyone knows a way either to convert the relative to page coordinates into screen coordinates, OR an alternative way of getting screen coordinates of a selected word in a Word'97 document just like GetPoint does I would appreciate it if he could share it with me.

    Many Thanks in advance

    Nick

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: VBA:Word97: Help with screen coordinates

    As this pertains to Word VBA rather than VB, it has been moved to Office Development.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width