1. Gimmy Susan
  2. PowerBuilder
  3. Monday, 11 November 2024 16:13 PM UTC

 

Hello everyone
I have slowdown problems with opening dddw
Ecosystem:
windows11
pb2022r3 (build 3391), but I have the same problem with pb2019r3
pfc

If I open many windows (windows with many fields and dddw) when I click on the dddw to open them, they open late. The positioning on the field happens immediately, but then there is a significant wait before the list of dddw values ​​is displayed. (I have gotten to have waits of 3 seconds).
It seems that if open windows increase (complex windows: many fields, many dddw, many tabpages) the response time of opening the dddw increases proportionally.
You understand that in an MDI application it is not nice to limit the opening of windows and this causes strong slowdowns.

I'll start by saying that
•⁠ ⁠RAM is not in crisis
•⁠ PROCESSOR is not in crisis
•⁠ ⁠I checked with debug and the only event that fires is the click and it has no code that can interfere. I even deleted all the code to make sure there were no recursive ones that cause problems.
•⁠ ⁠dddw are loaded when the window is opened and not when it is clicked.

 

thanks in advance for your reply

David Peace (Powersoft) Accepted Answer Pending Moderation
  1. Tuesday, 12 November 2024 10:55 AM UTC
  2. PowerBuilder
  3. # 1

Are you using Themes? If so is it better without the themes being applied?

Comment
  1. Gimmy Susan
  2. Tuesday, 12 November 2024 14:58 PM UTC
no
  1. Helpful
  1. David Peace (Powersoft)
  2. Tuesday, 12 November 2024 15:03 PM UTC
I guess that means that you are not using Themes, so that eliminates that overhead.

Is this occurring on all machines or just some?
  1. Helpful
There are no comments made yet.
Gimmy Susan Accepted Answer Pending Moderation
  1. Tuesday, 12 November 2024 09:52 AM UTC
  2. PowerBuilder
  3. # 2

Further tests show that if we approach 7000/8000 handles the system has that problem.
Below is the code we use for the test.
we also noticed that when we reach 10000 the program crashes.

 

Could it be? Does it happen to anyone?

 

====================================================================

Function long GetCurrentProcess () Library "kernel32"
Function long GetGuiResources (ulong hProcess,  long  uiFlags) Library "user32.dll"

long ll_guiresource, llguiobj
ulong        hdlProcessHandle
if isvalid(inv_statusbar) then

    hdlProcessHandle = GetCurrentProcess()
    llguiobj = GetGuiResources(hdlProcessHandle, 1)
    inv_statusbar.of_modify("handle", " " + string (llguiobj) + " / 9999")
    
    if llguiobj > 8000 then
        messagebox('Avviso', 'Stai raggiungendo il limite delle finestre aperte, è opportuno chiudere alcune finestre!', Exclamation!)
    end if
end if
===========================================================================

Comment
  1. Chris Pollach @Appeon
  2. Tuesday, 12 November 2024 13:24 PM UTC
Hi Gimmy;

Yes, 10K GDI handles is the typical install default limit used by the Window's O/S. The GDI maximum value that you can set is 65K. You can control this value as follows ...



For GDI handles change this Registry Key:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\GDIProcessHandleQuota

Range: 256 - 65,536. Default value: 10000



Tip: App GUI handle maximum can also be increased as follows ...

For USER handles change this Registry Key:



HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\USERProcessHandleQuota

Range: 200 - 18,000. Default value: 100



HTH

Regards ... Chris
  1. Helpful
  1. mike S
  2. Tuesday, 12 November 2024 19:12 PM UTC
10K handles?!!



do you use a lot of datastores? If so, there is a pb.ini setting to have them NOT use a handle
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Monday, 11 November 2024 20:42 PM UTC
  2. PowerBuilder
  3. # 3

"when I click on the dddw to open them, they open late"

 

I missed this when i first read it.  so it isn't the retrieve of the datawindows that is  your issue, it is when a user clicks on the dddw that it does not display the drop down until a delay?

Comment
  1. Gimmy Susan
  2. Tuesday, 12 November 2024 09:23 AM UTC
Hi Mike.

yes

after clicking on the dddw the focus moves correctly and immediately, but the curtain goes down with an annoying delay
  1. Helpful
There are no comments made yet.
John Fauss Accepted Answer Pending Moderation
  1. Monday, 11 November 2024 17:04 PM UTC
  2. PowerBuilder
  3. # 4

Do all DDDW's exhibit this issue, or only a few?

Resources are finite. Also, the more "things" PB has to keep track of internally, the greater I would expect the impact of overhead of managing all of the objects to increase.

Can the latentcy your app is experiencing be attributed to repeated data retrievals of large amounts of data in the DDDW's? 

Approximately how many rows in the DDDW's?

How many columns in the DW's?

How many rows in the DW's?

How many windows are open?

32-bit or 64-bit?

Comment
  1. Gimmy Susan
  2. Tuesday, 12 November 2024 09:37 AM UTC
Interesting questions.

The tests say that:

- all dddw have the same problem. even those with only 3 items.

- we do not have retrieves that come into play

- the dw is singlerow, the dddw gives problems even with 3 items.

- the problem occurs both in 32 and 64 bit

- the number of open windows gives some suggestions. eg: if I open 20 'simple' windows I have no problems. If I open 5 very populated windows of objects it gives problems.



[cit]

Resources are finite. Also, the more "things" PB has to keep track of internally, the greater I would expect the impact of overhead of managing all of the objects to increase

[end cit.]

maybe the problem is here. I do further tests
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Monday, 11 November 2024 16:35 PM UTC
  2. PowerBuilder
  3. # 5

Hi Ginny;

  • Is this when running the App from the IDE, EXE or both?
  • Does this only happen on your development machine?
  • Do other developers/ App users have this issue?

Regards ... Chris 

Comment
  1. Gimmy Susan
  2. Tuesday, 12 November 2024 09:39 AM UTC
- It happens in both IDE and EXE

- It also happens in my development machine (I use intel I9+128RAM)

- all users and all developers have the same problem
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Monday, 11 November 2024 16:23 PM UTC
  2. PowerBuilder
  3. # 6

are you caching the dddw values? 

do you have autoselect on, or are you manually retrieving them (in a posted event or triggered)?

do you retrieve all of them regardless of whether the user can see them (you mention many tab pages)?

Comment
  1. Gimmy Susan
  2. Tuesday, 12 November 2024 09:40 AM UTC
- no

- manually on windows open

- yes
  1. Helpful
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.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.