[Gambas-user] GridView not refreshing

Benoît Minisini gambas at ...1...
Thu Feb 5 11:20:03 CET 2009


> Well, I'll try with your suggestion, but sincerely I'm afraid that I'll get
> the same ugly result I had the first time, when I wanted to display tens of
> thousands rows with the synthax
> gV.[m,o].Text=....
> It took eternity to display all the rows. But since I'm using Data event it
> speeded up the process at least 100 times. I thought that when I already
> have a filled table, and I just want to sort its items, I could use again
> the method Data. You know the speed is very important.
> But can you explain me why it doesn't want to do the same action, when the
> GridView is already filled? I've tried to do gV.Clear() to recreate the
> table but it didn't work. Logically there's a contradiction!
> Thanks

You didn't understand what the Data event is.

Either you fill the GridView with the [] operator, and then you can use the 
Clear method to void it, or you use the Data event, and then you must provide 
the data when the GridView asks for it. 

You must not call the Data event handler yourself, it will do nothing.

If you want to see sorted data, then you must write your Data event handler so 
that it returns the data sorted.

Regards,

-- 
Benoît




More information about the User mailing list