Graphic Coordinates

How can I open a dialog window that is “pinned” to a form window like a dialog sheet? Or, how can I get the dialog window to open relative to a form window that is being displayed on a second monitor? I have tried this.

object “PeopleSearchButton”
opendialog “SmallSearchWidget”,“Rectangle”,xytoxy(objectinfo(“rectangle”),“s”,“w”),“Titlebar”,“no”

and it is not working, it ends up on the first monitor, upper left corner.

It seems Panorama does not recognize a second monitor. If I have a form open on my second monitor with a button that triggers a simple message statement it will open that message dialog on the far left side of the first monitor instead of centered in the second monitor.

Note: a dialog sheet will open on the proper form in the second monitor.

You should use opendialogsheet, not opendialog.

Though actually I would strongly urge using rundialog with the sheet=true option. This is how all of Panorama’s own sheet dialogs are done (find/select, morph, sort, etc.)

Understood, but I don’t want the sheet, I just want it to be form relative. Is it possible?

You should be able to open a form in any position on any monitor. It won’t be “pinned”, though – moving the underlying form will not move the new form.

If you want the new form to be positioned relative to a visible form, just use windowinfo( to get the rectangle of the visible window in global coordinates, then adjust as needed with rectanglecenter(, rectangletweak(, etc.

This does not appear to be the case. If I use a negative value for the left position it will open the form at the 0 position on the main monitor instead of the requested positon on the second monitor. I had a form open on the second monitor and using getwindow I got 71,-951,724,845 returned with -951 the left position. If I then have a button on that form with code to open a second form at the same coordinates it will instead open it on the far left edge of the main monitor. Looks like a bug to me.

Ok, some further information which will clear this up. I had Panorama X set to “Desktop on Display 1” under the Options of the Panorama X dock popup. Once I set it to “All Desktops” it would work properly and open the second form on the second monitor as requested.


Evidently there are certain restrictions when using specific desktops in OS X. I wonder if Steve also has Panorama X set to a specific desktop.

Hi Gary,

I will check it out and let you know.


I’d never noticed that option before. On all of my software it is set to None.

If you have more than one desktop on one monitor, you can set which desktop it appears in with that option.