Try this example
- Code: Select all Expand view RUN
#include "FiveWin.ch"
*-------------------------------------------------------------------------------------------
Function Main
*-------------------------------------------------------------------------------------------
LOCAl oWnd
DEFINE WINDOW oWnd ;
TITLE "Main Form" ;
MDI
ACTIVATE WINDOW oWnd MAXIMIZED ON INIT NewForm(oWnd)
return(nil)
*-------------------------------------------------------------------------------------------
Function NewForm (oMadre)
*-------------------------------------------------------------------------------------------
local oForm1
local oForm2
local oDlg
local nX := 4 / nLoWord( GetDlgBaseUnits() )
local nY := 8 / nHiWord( GetDlgBaseUnits() )
DEFINE DIALOG oDlg ;
OF oMadre ;
FROM 100, 100 TO 700, 900 ;
PIXEL ;
TITLE "Dialog 1"
@ 10*nY, 10*nX SAY "Codice articolo" ;
OF oDlg ;
UPDATE ;
PIXEL ;
SIZE 100 * nX, 20 * nY
ACTIVATE DIALOG oDlg NOWAIT
*--------------------------------------------------------------------------------------
DEFINE WINDOW oForm1 MDICHILD ;
OF oMadre ;
FROM 100, 100 TO 700, 900 ;
PIXEL ;
TITLE "New form 1"
@ 10, 10 SAY "Codice articolo" ;
OF oForm1 ;
PIXEL ;
UPDATE ;
DESIGN ;
SIZE 100, 20
ACTIVATE WINDOW oForm1
*--------------------------------------------------------------------------------------
DEFINE WINDOW oForm2 ;
FROM 100, 100 TO 700, 900 ;
PIXEL ;
TITLE "New form 2"
@ 10, 10 SAY "Codice articolo" ;
OF oForm2 ;
PIXEL ;
UPDATE ;
DESIGN ;
SIZE 100, 20
ACTIVATE WINDOW oForm2
return(nil)
the size of MDICHILD are wrong
thanks