Steve,
Thank you for taking the time to research this and build a prototype. Your solution is similar to one just posted by Cetin. Cetin's code has the advantage of not requiring a VB wrapper.
Again, thanks for your help and effort on this thread!
Regards,
Malcolm
>Have you figured out how to get the position of the text cursor? I found out that it is called the 'caret'. There is an API call called getCaretPos() that returns the caret position relative to the current client window.
>
>I have put a little VB wrapper DLL around it and it seems to work well within VFP.
>
>
>oCaret = createobject("caretWrap", "caret")
>? oCaret.getposition()
>
>
>I set it up to return a string. For example, "x165y10" means the caret is at position (165, 10). I guess it could have 2 more methods: getXPos() and getYPos().
>
>Let me know if you want the VB code, or I can email you the VB project so you can mess with it.