Thanks,
Dutch
- Code: Select all Expand view RUN
#include 'fivewin.ch'
#include 'xbrowse.ch'
Function Main
local oDlg, oLbx, oBtn, oSay, oGet
local aMonths := {}
local n, o, x, z, cField, nMonth, nYear, dStart, lSave, cPeriod, cOpen
for n := 1 to 12
aadd( aMonths , { 'Month '+str(n), ;
' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ;
'1', '1', ' ', ' ', '1', ' ', ' ', ' ', ' ', ' ', ;
' ', ' ', ' ', '1', ' ', ' ', ' ', ' ', ' ', ' ', ;
' ' } )
next
DEFINE DIALOG oDlg FROM 0, 0 TO 500,800 TITLE 'Yield Management' PIXEL
REDEFINE XBROWSE oLbx ARRAY aMonths ;
COLUMNS 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ,;
11, 12, 13, 14, 15, 16, 17, 18, 19, 20 ,;
21, 22, 23, 24, 25, 26, 27, 28, 29, 30 , 31, 32 ;
HEADERS 'Month/Year', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', ;
'11', '12', '13', '14', '15', '16', '17', '18', '19', '20', ;
'21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31' ;
FIELDSIZES 130, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, ;
20, 20, 20, 20, 20, 20, 20, 20, 20, 20, ;
20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20 ;
OF oDlg
// error on following lines
for x := 2 to 32
oLbx:aCols[x]:AddBmpFile("GO.BMP")
oLbx:aCols[x]:bBmpData := {|| iif(Eval(oLbx:aCols[x]:bStrData)='1',1,0) }
oLbx:aCols[x]:nDataBmpAlign := AL_CENTER
next
oLbx:CreateFromCode()
oDlg:oClient := oLbx
ACTIVATE DIALOG oDlg ON INIT oLbx:SetFocus()
return nil