1. Andreas Keiser
  2. PowerBuilder
  3. Tuesday, 18 June 2019 09:33 AM

Dear Appeon Support Team

I already reported this issue 1 year ago.

The same issue still exists with PB Version 2019 Build 2082.

 

When running a PB-Desktop-Application in a RDP session (Windows 10 host), mouse wheel scrolling doesnt work appropriately.

One mouse wheel click or tick scrolls the datawindow one whole page down or up instead of 3 lines!

Notepad and other applications are scrolling correctly, only PB Applications not.

 

I think this is an issue. Or is there a datawindow or PB setting that could resolve this Problem?

 

 

I uploaded two screen casts.

 

1.  Recording_rdp.rar (Recording.avi, shows datawindow scrolling and Notepad scrolling with mouse wheel )

The datawindow ist scrolled 3 times (3 ticks or clicks) with the mouse wheel.

After the first scroll click/tick the item on top of the datawindow is "C.A1300 Kiessand ….."

After the second one the top item is "Diverses Kokosschnur..."

After the third one the top item is "H.A1000 Bio-Universalerde"

 

As you can see in Notepad the scrolling is correct (3 by 3 line by each mouse wheel tick) but not in PB (page wise)!

 

2. Recording_local.rar (Recording_local.avi)

The same application executed locally on the PC (no RDP session). The mouse Wheel scrolling is correct:

The datawindow ist scrolled 3 times (3 ticks or clicks) with the mouse wheel.

After the first scroll click/tick the item on top of the datawindow is "A.A1002 Facharbeiter ….."

After the second one the top item is "A.A1005 Lehrling 1. Lehrjahr"

After the third one the top item is "A.A1008 Praktikant"

 

When the host system is Windows 7 mouse wheel scrolling works fine in RDP-Sessions. Not so with Windows 8 and 10.

 

Thanks a lot.

Best regards

Andreas

 

Attachments (2)
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Thursday, 30 April 2020 10:39 AM
  2. PowerBuilder
  3. # 1
0
Votes
Undo

I've updated (again) the code that I previously pasted here. It wasn't working at all, my apologies.

Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Tuesday, 14 April 2020 09:05 AM
  2. PowerBuilder
  3. # 2
0
Votes
Undo

I've updated my solution with some setredraw() to prevent the scroll to become 'sluggish'.

I have NOT updated the sample application that I also posted here previously.

New code:

CONSTANT uint WM_MOUSEWHEEL = 522

CHOOSE CASE message.number
	CASE WM_MOUSEWHEEL
		// v1 and v2, mjl, 13/04/20: Since win8 and w10 totally ignore the mouse settings when working remotely, I've re-introduced the code to scroll:
		// First check the user isn't "zooming" by using CTRL+mouseWheel:
		IF KeyDown( keyControl!) then
			RETURN 0
		END IF
		CONSTANT uint SPI_GETWHEELSCROLLLINES = 104
		CONSTANT Long WM_VSCROLL = 277
		CONSTANT Long SB_LINEDOWN = 1
		CONSTANT Long SB_LINEUP = 0
		
		int li_WheelMouseLine, li_index
		int li_lines

		// Function boolean SystemParametersInfoW(uint wActon, uint wParam, REF int pvParam, uint fUpdateProfile) Library "USER32.DLL"
		SystemParametersInfoW(SPI_GETWHEELSCROLLLINES, 0, ref li_WheelMouseLine, 0)
		li_lines = IntHigh(wParam) / 120
		this.SetRedraw(false)
		IF li_lines > 0 THEN
			FOR li_index = 1 TO li_WheelMouseLine
				Send(Handle(THIS), WM_VSCROLL, SB_LINEUP,0)
			NEXT
		ELSE
			FOR li_index = 1 TO li_WheelMouseLine
				Send(Handle(THIS), WM_VSCROLL, SB_LINEDOWN,0)
			NEXT
		END IF
		this.SetRedraw(true)
		message.processed = true // don't process the event anymore, since we've already dealt with it.
		RETURN 1 // even when people claim it should be 0 !!!
END CHOOSE

RETURN 0

 

 

Comment
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Monday, 13 April 2020 16:27 PM
  2. PowerBuilder
  3. # 3
0
Votes
Undo

Hi Andres;

  Yes, this is a "legacy" issue dating back to the Sybase versions of PB. The mouse scrolling issue has certainly been well reported with RDP and Citrix software even in the PB 12.6 days. Of course, Appeon PB is based on the PB 12.6 codeline - which is what SAP turned over to Appeon in 2016 and what PB2017 and higher versions are based on. 

  I also suspect that other remote software (ie: like Andres reports) will also have this issue. If you reported this issue before through a support ticket, please post a response asking engineering for an update.

Regards .. Chris

Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Monday, 13 April 2020 13:16 PM
  2. PowerBuilder
  3. # 4
0
Votes
Undo

Here's a little sample application, made with  PB2019 R2: see attached

 

Attachments (1)
Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Monday, 13 April 2020 13:05 PM
  2. PowerBuilder
  3. # 5
0
Votes
Undo

(Edited: I've changed the type of WM_MOUSEWHEEL to uInt as Message.Number is an unsigned int.)

Hi Andreas,

I've tested your case (not using RDP, but a differenct remote connection "Splashtop") and indeed, W10 seems to ignore the settings for the line-scroll. It scrolls a page, always when on remote.

Honestly I think this is a Windows 10 problem and not an Appeon problem.

Anyway, long story short, here's some code to solve your problem.

You have to declare this external function:

Function boolean SystemParametersInfoW(uint wActon, uint wParam, REF int pvParam, uint fUpdateProfile) Library "USER32.DLL"

And  then paste this code in the datawindow's "other" event.

CONSTANT uint WM_MOUSEWHEEL = 522

CHOOSE CASE message.number
	CASE WM_MOUSEWHEEL
		// v1 and v2, mjl, 13/04/20: Since win8 and w10 totally ignore the mouse settings when working remotely, I've re-introduced the code to scroll:
		// First check the user isn't "zooming" by using CTRL+mouseWheel:
		IF KeyDown( keyControl!) then
			RETURN 0
		END IF
		CONSTANT uint SPI_GETWHEELSCROLLLINES = 104
		CONSTANT Long WM_VSCROLL = 277
		CONSTANT Long SB_LINEDOWN = 1
		CONSTANT Long SB_LINEUP = 0
		
		int li_WheelMouseLine, li_index
		int li_lines

		// Function boolean SystemParametersInfoW(uint wActon, uint wParam, REF int pvParam, uint fUpdateProfile) Library "USER32.DLL"
		SystemParametersInfoW(SPI_GETWHEELSCROLLLINES, 0, ref li_WheelMouseLine, 0)
		li_lines = IntHigh(wParam) / 120
		this.SetRedraw(false)
		IF li_lines > 0 THEN
			FOR li_index = 1 TO li_WheelMouseLine
				Send(Handle(THIS), WM_VSCROLL, SB_LINEUP,0)
			NEXT
		ELSE
			FOR li_index = 1 TO li_WheelMouseLine
				Send(Handle(THIS), WM_VSCROLL, SB_LINEDOWN,0)
			NEXT
		END IF
		message.processed = true // don't process the event anymore, since we've already dealt with it.
		this.SetRedraw(true)
		RETURN 1 // even when people claim it should be 0 !!!
END CHOOSE

RETURN 0
Comment
I'll upload a sample app to which I also add some extra code. We have to check the user is not trying to ZOOM the dw by using the CTRL key simultaneously.
  1. Miguel Leeuwe
  2. Monday, 13 April 2020 13:08 PM
There are no comments made yet.
Prashant Mungase Accepted Answer Pending Moderation
  1. Monday, 13 April 2020 09:46 AM
  2. PowerBuilder
  3. # 6
0
Votes
Undo

Hello Appeon Team,

 

Can we please have some updates on this issue.

 

Thanks,

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.