- Tomas Beran
- PowerBuilder
- Wednesday, 4 May 2022 03:59 PM UTC
Hi
Dual monitor vs. Response window behave strangely. Maybe someone has solved it before.
I've a main window and an about box. In the about box there's code
move ( w_genapp_main.x , w_genapp_main.y)
in the Open event.
It works almost everywhere as expected with one exception: In case w_genapp_main starts on left screen and bigger part is on the right screen then the about box is catapulted to outer space.
I tried different windows setups but with no any significant change. It looks like Windows tries to push the window to a screen where the most of the window surface is present. It collides with PB and the result is the window is moved with Windows and then again with PB.
If I change the open script to
POST move ( w_genapp_main.x , w_genapp_main.y)
then it works everywhere. But it's nasty because I'm afraid internally the window moves somewhere and then it's re-positioned. Plus I don't like personally asynchronous calls because it's hard to debug such code. I can use Activate() event but it's almost the same.
Printscreens are attached, example application is attached.
For reproduction you need two or more monitors.
Do you have any idea how to solve it?
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.