publi oform
oform=newObject("asup")
oform.show
read events
retu
DEFINE CLASS asup AS form
Top = 0
Left = 0
Height = 429
Width = 880
autocenter=.t.
showWindow=2
Name = "Form1"
ADD OBJECT grid1 AS grid WITH ;
Anchor = 15, ;
Height = 433, ;
Left = 1, ;
Top = 0, ;
Width = 877, ;
Name = "Grid1"
PROCEDURE Destroy
use in select("ycurs")
dele file ycurs.dbf
clea events
ENDPROC
PROCEDURE grid1.Init
_screen.windowstate=1
close data all
sele * from home(1)+"samples\data\customer" into table ycurs1
sele * from home(1)+"samples\data\customer" into table ycurs2
sele * from home(1)+"samples\data\customer" into table ycurs3
sele * from home(1)+"samples\data\customer" into table ycurs4
sele * from home(1)+"samples\data\customer" into table ycurs5
sele * from home(1)+"samples\data\customer" into table ycurs6
sele ycurs1
copy stru to ycurs.dbf
use ycurs alias ycurs
sele ycurs
appe from "ycurs1.dbf"
appe from "ycurs2.dbf"
appe from "ycurs3.dbf"
appe from "ycurs4.dbf"
appe from "ycurs5.dbf"
appe from "ycurs6.dbf"
close data all
for i=1 to 6
dele file ("ycurs"+trans(i)+".dbf")
endfor
use ycurs alias ycurs
sele ycurs
with this
.recordsource="ycurs"
.recordsourcetype=1
.deletemark=.f.
.gridlines=0
.autofit()
.SetAll("DynamicBackColor", "IIF(MOD(RECNO( ), 2)=0, RGB(212,210,208) , RGB(0,255,0))","column")
.Column3.DynamicBackColor = "rgb(255,164,164)"
.column5.Dynamicbackcolor ="rgb(255,255,0)"
.column3.fontbold=.t.
.column3.forecolor=rgb(128,0,64)
locate
.parent.caption=trans(reccount())+ " records loaded"
endwith
ENDPROC
ENDDEFINE