#include "FiveWin.ch"
#include "xbrowse.ch"
FUNCTION MAIN()
LOCAL oDlg1, nOldOption := 1
LOCAL oBrw1, oBrw2, oBrw3, oBrw4, oBrw5
aZeit := { "06:00"," 15", " 30"," 45", "07:00"," 15", ;
" 30"," 45", "08:00"," 15", " 30"," 45", ;
"09:00"," 15", " 30"," 45", "10:00"," 15", ;
" 30"," 45", "11:00"," 15", " 30", " 45", ;
"12:00"," 15", " 30", " : ", " " }
// ---- Dialog and folder ----
DEFINE DIALOG oDlg1 RESOURCE "Liste9" PIXEL ;
TITLE "Touren-Planung" ;
STYLE nOr( WS_POPUP, WS_BORDER, WS_THICKFRAME )
REDEFINE FOLDEREX oFld ID 110 PROMPT "Tourenplan", "&Patienten-Daten", "&Ortspläne", "&Pfleger" ;
DIALOGS "Tourliste", "Tour1", "Tour2", "Tour3" ROUND 5 ;
ON CHANGE ( nPage := oFld:nOption, ;
nOldOption := oFld:nOption, ;
oFld:aDialogs[ nPage ]:Update() )
// ----- 1 xbrowse in folderpage 1
USE "CUSTOMER" NEW SHARED ALIAS "CUSTOMER"
REDEFINE XBROWSE oBrw1 ID 110 OF oFld:aDialogs[ 1 ] AUTOSORT ;
COLUMNS { "FIRST", "LAST", "STREET", "CITY" } ;
ALIAS "CUSTOMER"
oBrw1:lFooter := .T.
// ----- 2 xbrowse in folderpage 1
USE "TOURBEZ" NEW SHARED ALIAS "TOURBEZ"
REDEFINE XBROWSE oBrw2 ID 120 OF oFld:aDialogs[ 1 ] ;
COLUMNS { "TOUR", "TSORT" } ;
ALIAS "TOURBEZ"
oBrw2:lFooter := .T.
// ----- Array in folderpage 1
REDEFINE XBROWSE oBrw3 ID 130 OF oFld:aDialogs[ 1 ] ;
COLUMNS { 1 } ;
ARRAY aZeit LINES CELL
oBrw3:lFooter := .T.
// ----- 3 xbrowse in folderpage 1
USE "LEISTUNG" NEW SHARED ALIAS "LEISTUNG"
REDEFINE XBROWSE oBrw4 ID 140 OF oFld:aDialogs[ 1 ] AUTOSORT ;
COLUMNS { "LEISTUNG", "KENNER" } ;
ALIAS "LEISTUNG"
oBrw4:lFooter := .T.
// ------------------------ unknown POPUP !!!!
// ----- xbrowse in folderpage 2
USE "PFLEGER" NEW SHARED ALIAS "PFLEGER"
REDEFINE XBROWSE oBrw5 ID 110 OF oFld:aDialogs[ 4 ] AUTOSORT ;
COLUMNS { "NACHNAME", "VORNAME", "SIGNAL", "TELEFON", "QUALIFIKAT" } ;
ALIAS "PFLEGER"
oBrw5:lFooter := .T.
ACTIVATE DIALOG oDlg1 CENTER
CLOSE DATABASE
RETURN NIL