This has got me pulling my hair out, all I want to do is get the cursor position within a client window in the same units as the window coordinates.
If I use;
Expand|Select|Wrap|Line Numbers
- Private Declare Function GetClientRect Lib "user32" (ByVal hwnd As Integer, ByRef lpRect As RECT) As Integer
Expand|Select|Wrap|Line Numbers
- Private Structure RECT
- Dim Left As Long
- Dim Top As Long
- Dim Right As Long
- Dim Bottom As Long
- End Structure
Expand|Select|Wrap|Line Numbers
- Dim CR as RECT
- GetClientRect(m_LastHwnd, CR)
I'm sure it can't be too hard, I'm just having trouble searching for it since most of the keywords one would use are rather common and return hundreds if not thousands of entries.
Would appreciate any ideas or tips and am using VB.Net 2005.
TIA
Andy