Another odd TListView issue lazarus / 31-LCL ---------------------------------------------------------------------- johnkdevnull · 2012-09-24 22:20 I want to open a new form on double clicking a Tlistview component.  However when I set it up and show a new modal form, if I then cancel out of the form the TListView component goes into that weird rubberband selection process and crashes if I left click out of it. I've created a test project to illustrate.  Double click on the ListView on the main form and then hit the cancel button on the resulting modal form to experience the problem. I'm using the SVN version of Lazarus 1.1 - SVN version 38778 on x86_64, fedora 17 (GTK2). ---------------------------------------------------------------------- Dick, from the internet · 2012-09-26 16:37 Interesting problem; I am not sure why this happens, but to correct it, I set MultiSelect to false. Code: [Select]procedure TForm1.ListView1DblClick(Sender: TObject); begin    Form2 := TForm2.Create(application);    Form2.ShowModal;    Form2.Free;    ListView1.MultiSelect := False;  //<< this fixes it on my system. end; edit:  I see now - you have MultiSelect := True in Object Inspector; so the error occurs even before opening the modal form if you hold down left mouse and select an area that does not include any of the items.  You need to trap this error in the event the user makes a selection of 0 items. If you do select multiple items with rubberband selection, right click will release them and give no error.   regards,    geno ---------------------------------------------------------------------- johnkdevnull · 2012-09-26 22:32 Thanks for your response geno.  However my application needs multiselect.  So your workaround isn't really useful.  It is a bug in my opinion and not a programming error. I suppose I am hoping that a Lazarus developer will agree with me that this is a bug and fix it.  (Same as happened with my last issue with TListView) ---------------------------------------------------------------------- johnkdevnull · 2012-09-26 22:44 Bug report created.    Bug number 0022991. ---------------------------------------------------------------------- johnkdevnull · 2012-09-27 19:07 Bug #0022991 resolved in SVN revision 38875.