[Gambas-user] make Label background from Database field
Vassilis K
vkan53 at ...2300...
Thu Oct 15 23:51:03 CEST 2009
Here is the new routine with all the testings that I tried:
PRIVATE $alblTime AS NEW Object[]
PUBLIC SUB Form_Open()
DIM i AS Integer
DIM rsThesi AS Result
DIM iD AS Long
ME.Title = "Σχέδιο θέσεων Camping"
MODMain.Connect()
rsThesi = MODMain.$Con.exec("select * from egrafes where elenchosAnax =
0")
$alblTime.Resize(100)
$alblTime[iD] = NEW Label(ME)
FOR iD = 1 TO rsThesi.Count - 1
$alblTime[iD].Background = Color.Red
NEXT
MODMain.$Con.Commit()
END
I get the error "Null Object" at line: "$alblTime[iD].Background = Color.Red"
I 'll continue testing!
You are right about the loop variant Dimitri. It must be rdThesi.Count-1.
More information about the User
mailing list