Hi,

I have usually have 2 monitors available but not always.

I use one for displaying maps and the other for the data on a called form.
How do 1 get Maps on 1 and Data to appear on the other without dragging the form onto the second monitor.

Thanx

P.

Recommended Answers

All 3 Replies

"Screen.Monitors" has a list of installed monitors, and Forms have the "monitor" property where you could try to fix where you want it to appear in the FormCreate event... have you tried this (i don't have 2 monitor here to give it a try)?

(All this info just typing "monitor" on the delphi help)

Thanks but I already looked at monitors but monitornum is read only


"Screen.Monitors" has a list of installed monitors, and Forms have the "monitor" property where you could try to fix where you want it to appear in the FormCreate event... have you tried this (i don't have 2 monitor here to give it a try)?

(All this info just typing "monitor" on the delphi help)

Each TMonitor has its own left and top intial position: if your second monitor is on the left side and main monitor is 1600 width, its left property can be like 1601 (and top = 0 in that case), so on Form.FormCreate you can read this and make

Self.Left:= Screen.Monitors[1].Left;

(for instance), so placing your form depending on monitor top, left, height and width should make it appear on center of the secondary monitor (again, not tested!).

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.