Le 07/03/2015 18:41, Gary Emms a écrit : > Hi > I'm trying to follow a tutorial from Linux Format. I have 2 list boxes > and I'm trying to move an entry from one to the other using: > > Public Sub btnLeft_Click() > > Dim i As Integer > 'transfer selected itelms to left > For i = 0 To lstInCar.Count - 1 > If lstInCar[i].Selected Then > lstAtHome.Add(lstInCar[i].Text) > Endif > Next > 'clear the entries from the left (backwards) > For i = lstInCar.Count - 1 To 0 Step - 1 > If lstInCar[i].Selected Then > lstInCar.Remove(i) > Endif > Next > End > > it works fine except, If, and only if, I select the first item in the > list after it is deleted the new top item is automatically selected. Is > this a bug or am I doing something wrong? > Cheers > Gary >
This is fixed in revision #6955: now the selection correctly takes into account removed or added items. Regards, -- Benoît Minisini ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user