[Gambas-user] Re: Columnview key

Benoit Minisini gambas at ...1...
Tue Dec 27 19:51:21 CET 2005


On Tuesday 27 December 2005 19:41, Rohnny Stormo wrote:
> Hi Benoit.
>
> When you have a listbox with several items, and some of them in the
> middle are deleted
> then it could be a problem.
> Yes I could do a counter but it's harder to keep track of everything,
> all variables, when then program should do alot of stuff, and have alot
> of variables.  The project I'm doing is a billing system for small
> buisness needs for northen country.
> I think some processes could be simplyfied with these options.
> But then, your the boss ;)  your doing a fantastic job.
>
> Happy newyear.
>
> Rohnny
>
>

I just wanted to tell you that I think there is a problem somewhere in your 
design...

Each element of the columnview is indexed by a string key.

When you put an item in the columnview, it represents something that is stored 
elsewhere, and that is identified by another key, not necessarily a string.

So it just a matter of transforming this key into a string, and vice-versa.

Key of the object <=> String key in the column view.

For example, if you put a list of bills in the column view, it could be:

Bill number identifying the bill in the database <=> Bill number converted to 
string as column view key.

You should not need intermediate numeric indexes.

How do you identify the objects you want to be represented in the columnview?

-- 
Benoit Minisini





More information about the User mailing list