-
Steen Jakobsen
- PowerBuilder
- Tuesday, 7 July 2026 10:31 AM UTC
Environment: PowerBuilder 2025 R2, Runtime 25.1.0.6430, 64-bit. Application HighDpiMode = PerMonitorV2(4). Windows 11.
Issue: When the compiled EXE starts while the PRIMARY monitor is scaled above 100% (e.g. 125% or 150%), the main window's initial layout is wrong — all controls are mispositioned (see screenshots). When the primary monitor is at 100%, the layout is correct, and dragging the window onto a scaled secondary monitor re-scales perfectly.
The wrong initial layout is corrected only by dragging the window to another monitor (a real DPI change). Once corrected, it stays correct — including when dragged back onto the scaled monitor. Minimizing/restoring the window does NOT correct it. The issue does not appear when running from the IDE.
Repro:
1. Set the primary monitor's scaling to 125%.
2. Build and run the application as an EXE.
3. The main window opens with all controls mispositioned.
4. Drag the window to a second (100%) monitor and back — the layout becomes correct.
Impact: Users on a single scaled display (e.g. a 150% laptop with no external monitor) have no way to trigger the correction, so the layout stays broken permanently.
Question: Is this a known issue, and is there a supported way to force the initial layout to compute at the correct DPI at startup?
Thanks
//Steen
ps. PB2025R2 is just awesome!!!
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.