Page 1 of 2

WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 1:46 am
by andyglezl
Hola
Habrá alguna forma de programar para poder abrir una ventana directamente en un segundo monitor por medio de nuestro programa ?
quizá... (o algo )
-------------------------------------------------------------------------------------------------------------------------------------
Hello
There will be some form of program to open a window on a second monitor directly through our program?
maybe ... (or something)

DEFINE WINDOW FormDetalle AT 0,0 WIDTH 1024 HEIGHT 560 TITLE " | NUEVA NOTA |" CHILD NOSIZE NOMAXIMIZE MONITOR 2
Second Monitor.jpg
Second Monitor.jpg (43.95 KiB) Viewed 8111 times

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 7:56 am
by mol
IMHO, the only way is to set coordinates of opened window

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 1:59 pm
by andyglezl
Gracias Mol, haré algunas pruebas...
------------------------------------------------
Thanks Mol, I do some tests ...

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 8:43 pm
by danielmaximiliano
Recerda que el debe tener la propiedad de pantalla extendida el segundo monitor.
si tu monitor esta en una resolucion de 1024x768

crea un form cajero ubicado en 0,0 y otro form usuario en 1025,0.

sino la otra solucion seria utilizar 2 aplicaciones comunicadas con mensajes entre si...

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 8:48 pm
by mol
It's hard to determine where second monitor "starts".
I'm working on two monitors: first 19" has resolution 1280x1024 and second 22" with resolution 1920x1080.
Both of them work in the same time...

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 9:42 pm
by danielmaximiliano
mol wrote:It's hard to determine where second monitor "starts".
I'm working on two monitors: first 19" has resolution 1280x1024 and second 22" with resolution 1920x1080.
Both of them work in the same time...
1° monitor

GetDesktopHeight() --> nDesktopHeight
GetDesktopWidth() --> nDesktopWidth
position 0 , 0 to nDesktopWidth, nDesktopHeight


2°monitor
GetDesktopHeight() --> nDesktopHeight2
GetDesktopWidth() --> nDesktopWidth2
position 0, nDesktopHeight + 1 .or. 2 to nDesktopWidth2, nDesktopHeight2 - 1 .or. 2

hope not wrong---
NOTE : forgiveness. Monitor extension widths are added ...
what remains are the high fixed monitors and these do not add up.

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 11:33 pm
by Pablo César
danielmaximiliano wrote: 1° monitor

GetDesktopHeight() --> nDesktopHeight
GetDesktopWidth() --> nDesktopWidth
position 0 , 0 to nDesktopWidth, nDesktopHeight


2°monitor
GetDesktopHeight() --> nDesktopHeight2
GetDesktopWidth() --> nDesktopWidth2
position 0, nDesktopHeight + 1 .or. 2 to nDesktopWidth2, nDesktopHeight2 - 1 .or. 2

hope not wrong---
Daniel,

IMHO this is not the right way because GetDesktopHeight() and GetDesktopWidth() will return with maximum screen size.

Considering fix (not changeable) size in Monitor 1 by Mark said:
mol wrote:I'm working on two monitors: first 19" has resolution 1280x1024
I believed should it be like this:

1st Monitor:

nHeight1 := 1280
nWidth1 := 1024

2nd Monitor:

nHeight2 := ( GetDesktopHeight() - nHeight1 )
nWidth2 := ( GetDesktopWidth() - nWidth1 )

My suggestion: nHeight1 and nWidth1, could it be variable receiving this parameters from line command or thru saved in INI file.

B.rgds

Re: WINDOW ON A SECOND MONITOR ?

Posted: Tue Jun 23, 2015 11:50 pm
by danielmaximiliano
Pablo César wrote:
danielmaximiliano wrote: 1° monitor

GetDesktopHeight() --> nDesktopHeight
GetDesktopWidth() --> nDesktopWidth
position 0 , 0 to nDesktopWidth, nDesktopHeight


2°monitor
GetDesktopHeight() --> nDesktopHeight2
GetDesktopWidth() --> nDesktopWidth2
position 0, nDesktopHeight + 1 .or. 2 to nDesktopWidth2, nDesktopHeight2 - 1 .or. 2

hope not wrong---
Daniel,

IMHO this is not the right way because GetDesktopHeight() and GetDesktopWidth() will return with maximum screen size.

Considering fix (not changeable) size in Monitor 1 by Mark said:
mol wrote:I'm working on two monitors: first 19" has resolution 1280x1024
I believed should it be like this:

1st Monitor:

nHeight1 := 1280
nWidth1 := 1024

2nd Monitor:

nHeight2 := ( GetDesktopHeight() - nHeight1 )
nWidth2 := ( GetDesktopWidth() - nWidth1 )

My suggestion: nHeight1 and nWidth1, could it be variable receiving this parameters from line command or thru saved in INI file.

B.rgds
Pablo : te falto un poco de lectura..
aclare que desde 0,0 to GetDesktopHeight(), GetDesktopWidth() para el monitor 1...
despues desde 0. GetDesktopHeight() + 1 to ( GetDesktopHeight() - nHeight1 ), nWidth2

la fila 0 en los 2 monitores es igual, cambia o puede cambiar el alto de los 2 monitores seria un error RESTAR ya que el monitor 1 pude ser mas chico que el monitor 2...

nWidth2 := ( GetDesktopWidth() - nWidth1 )

Re: WINDOW ON A SECOND MONITOR ?

Posted: Wed Jun 24, 2015 12:17 am
by Pablo César
Tenés razón Daniel, disculpame.

No tengo experiencia con 2 monitores.

Re: WINDOW ON A SECOND MONITOR ?

Posted: Wed Jun 24, 2015 12:23 am
by danielmaximiliano
Pablo César wrote:Tenés razón Daniel, disculpame.

No tengo experiencia con 2 monitores.
no tiene importancia, voy a hacer el jueves con la Notebook y el LED TV por medio de HDMI.