e.pagesView.mouse event  SOLVED

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
prime clinical systems
User
Posts: 211
Joined: Sun Aug 05, 2012 5:20 pm

e.pagesView.mouse event

Post by prime clinical systems »

Hi, finding that param1 returns the mouse windows message WM_LBUTTONDOWN, etc, and param2 stores what appears to be a long pointer... not sure to what, do you know?
Also in this event, I try this code:
Dim stClient As tagPOINT
Dim stScreen As tagPOINT
Dim IPXV As IPXV_PagesView
Set IPXV = Me.PDF.Inst.ActiveDocView.PagesView
Call IPXV.obj.ClientPtToScreen(stClient, stScreen)
If pEvent.Param1 = WM_LBUTTONDOWN Then
WriteLog "WM_LBUTTONDOWN X " & CStr(stScreen.X) & " Y " & CStr(stScreen.Y)
WriteLog "WM_LBUTTONDOWN X " & CStr(stClient.X) & " Y " & CStr(stClient.Y)
end if

Looking at the file written, shows only Screen X,Y returned, what am I doing wrong so Client is not returned? I want to insert form field at x,y, and with VB can't use pageHandler etc.
06-09-2017,20:20:49 ,WM_LBUTTONDOWN X 125 Y 234
06-09-2017,20:20:49 ,WM_LBUTTONDOWN X 0 Y 0
06-09-2017,19:50:09 ,Parm2: 208004128 -- pointer to what?
Thanks
CE
prime clinical systems
User
Posts: 211
Joined: Sun Aug 05, 2012 5:20 pm

Re: e.pagesView.mouse event  SOLVED

Post by prime clinical systems »

Ok second look I'm thinking the Param2 is pointer to the Client tagPoint perhaps the Screen tagPoint, but I have done the following, if anyone else runs across this VB6, might update your Wikki to indicate what is returned in param1, param2, thanks
If pEvent.ID = Me.PDF.Inst.Str2ID("e.pagesView.mouse") Then
Dim stClient As tagPOINT
Dim stScreen As tagPOINT
Dim MyPoint As POINTAPI
Dim IUIXobj As PDFXEditCtl.IUIX_Obj
Set IUIXobj = Me.PDF.Inst.ActiveDocView.PagesView.Obj
If pEvent.Param1 = WM_RBUTTONDOWN Then
GetCursorPos MyPoint 'windowsAPI
stScreen.X = MyPoint.X: stScreen.Y = MyPoint.Y
Call IUIXobj.ScreenPtToClient(stScreen, stClient)
WriteLog "WM_RBUTTONDOWN X " & CStr(stScreen.X) & " Y " & CStr(stScreen.Y)
WriteLog "WM_RBUTTONDOWN X " & CStr(stClient.X) & " Y " & CStr(stClient.Y)
'returns screen and client translated codes
'WM_RBUTTONDOWN X 851 Y 305
'WM_RBUTTONDOWN X 726 Y 71
End if
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: e.pagesView.mouse event

Post by Sasha - Tracker Dev Team »

Hello Clifford,

The events are being updated on the go - we will update this soon.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Post Reply