[Gambas-user] RichDBGrid Alpha

Fabien Bodard gambas.fr at ...626...
Mon Dec 10 16:07:57 CET 2007


This is a little encapsulation class to make rich grid viewer for  Database .

There is a dynamic Conditional set of class used by the gridview and a system 
to store and restore cells or anything that have a simple format in a string.
It store BackColor, ForeColor, Alignment, Font, Padding.

For exemple this :

Epuises = "BackColor: &FF0000&; ForeColor: &HFFFFFF&; Font: Bold,+2"
hCondition = NEW Conditions("salary", Conditions.EstSuperieur, 4000, Epuises)
hCondition.Add("salary", Conditions.EstInferieur, 6500)
$hDBGrid.CondFormats.Add(hCondition)

Say to change format on line where the salary > 4000 and < 6500

it set the bgcolor to red and the Forecolor to white set the font bold and 
increase it to grade +2

TODO

The Column Format.. i will use an array of format string ..

Spécific Column Format.. or better Specific Column conditionality

Some word are in french... sorry, the CFormat and Conditions classes can be 
used in many other cases.. 

An advise ?



Fabien

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gg-0.0.8.tar.gz
Type: application/x-tgz
Size: 31671 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20071210/8cd62466/attachment.bin>


More information about the User mailing list