Coupla ways to approach this. First, the Change event fires whenever the listbox selection changes, which would be the case if the row you are editing is selected and then they clicked in the unused portion of the listbox. If, as part of setting up edit mode, you clear the selection (ListIndex = -1), then this wouldn't work for you.
Second, you could handle it in the MouseDown event. In 2006 and later, you can use RowFromXY to retrieve the row they just clicked on, and if it isn't the row you are editing, you can "unset" edit mode. You could even return true out of the MouseDown if it isn't a valid row, and disallow clicking in the empty space. Tim > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Behalf Of > Roger Clary > Sent: Tuesday, December 12, 2006 1:52 PM > To: REALbasic NUG > Subject: Re: "non" listbox.cellclick event > > > > On Dec 12, 2006, at 1:48 PM, Michael wrote: > > > I have looked at the archives...but no help there, although I > > cannot believe this is not an uncommon issue. :-) > > > > Is there a listbox, "not cellClick" event.? > > For example. The user clicks a row of data....CellClick Sets ( a > > method) "InvokeEditMode". > > > > > > Now The user clicks outside the listbox. I can unset with > > "lostfocus", but how can one get the same functionality if the user > > has clicked into an unused portion of the listbox. > > > > Thank you all in advance....I am going to have to include all the > > names who have helped when this is done!! > > Listbox.ListIndex = -1 when a click occurs on other than a cell. > > Roger Clary > [EMAIL PROTECTED] > Class One Software > Educational Software for Lifelong Learning > > > _______________________________________________ > Unsubscribe or switch delivery mode: > <http://www.realsoftware.com/support/listmanager/> > > Search the archives of this list here: > <http://support.realsoftware.com/listarchives/lists.html> > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.5.432 / Virus Database: 268.15.16/582 - Release Date: > 12/11/2006 4:32 PM > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.432 / Virus Database: 268.15.16/582 - Release Date: 12/11/2006 4:32 PM _______________________________________________ Unsubscribe or switch delivery mode: <http://www.realsoftware.com/support/listmanager/> Search the archives of this list here: <http://support.realsoftware.com/listarchives/lists.html>
