# weblistbox doubleclick in scrollbar. bug??

**URL:** <https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551>\
**Category:** Web\
**Created:** [June 27, 2014, 12:16pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551 "2014-06-27T12:16:59Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Russ\_Lunn](https://forum.xojo.com/letter_avatar_proxy/v4/letter/r/5f9b8f/32.png) [@Russ\_Lunn](https://forum.xojo.com/u/Russ_Lunn)\
**Post date:** [June 27, 2014, 12:16pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/1 "2014-06-27T12:16:59Z")

</div>

hi,

i have a weblistbox with a vertical scrollbar.  
if the user doubleclicks in the scrollbar, the doubleclick event fires which is REALLY annoying!

any ideas how to stop it happening?  
i cant see anything to tell me the scrollbar width, to filter it by X coordinate  
i suspect it shouldnt fire the event if its in the scrollbar though.

any ideas?

---

<div class="post-metadata">

**Author:** ![Michel\_Bujardet](https://forum.xojo.com/user_avatar/forum.xojo.com/michel_bujardet/32/252_2.png) [@Michel\_Bujardet](https://forum.xojo.com/u/Michel_Bujardet)\
**Post date:** [June 27, 2014, 1:36pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/2 "2014-06-27T13:36:37Z")

</div>

[quote=104998:@Russ Lunn]hi,

i have a weblistbox with a vertical scrollbar.  
if the user doubleclicks in the scrollbar, the doubleclick event fires which is REALLY annoying!

any ideas how to stop it happening?  
i cant see anything to tell me the scrollbar width, to filter it by X coordinate  
i suspect it shouldnt fire the event if its in the scrollbar though.

any ideas?[/quote]

I ran a small project and simply grabbed the screen. On my Mac the scrollbar is 16 pixels wide. On PC use alt-PrtSc and measure on the picture 🙂

---

<div class="post-metadata">

**Author:** ![Russ\_Lunn](https://forum.xojo.com/letter_avatar_proxy/v4/letter/r/5f9b8f/32.png) [@Russ\_Lunn](https://forum.xojo.com/u/Russ_Lunn)\
**Post date:** [June 27, 2014, 2:08pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/3 "2014-06-27T14:08:53Z")

</div>

thanks michel,

but i’m looking for something in code, because i cant guarantee (i dont think) that the scrollbar will be that width on every browser.

---

<div class="post-metadata">

**Author:** ![Michel\_Bujardet](https://forum.xojo.com/user_avatar/forum.xojo.com/michel_bujardet/32/252_2.png) [@Michel\_Bujardet](https://forum.xojo.com/u/Michel_Bujardet)\
**Post date:** [June 27, 2014, 2:35pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/4 "2014-06-27T14:35:46Z")

</div>

[quote=105050:@Russ Lunn]thanks michel,

but i’m looking for something in code, because i cant guarantee (i dont think) that the scrollbar will be that width on every browser.[/quote]  
Good luck.  
… But … How many browsers are there to do a quick test ?

---

<div class="post-metadata">

**Author:** ![Brad\_Hutchings](https://forum.xojo.com/user_avatar/forum.xojo.com/brad_hutchings/32/143_2.png) [@Brad\_Hutchings](https://forum.xojo.com/u/Brad_Hutchings)\
**Post date:** [June 27, 2014, 2:48pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/5 "2014-06-27T14:48:04Z")

</div>

[quote=104998:@Russ Lunn]any ideas?  
[/quote]

Keep track of Microseconds() timestamp of the last CellClick. If the double-click happens too long after the last CellClick, ignore it. Should work great in the debugger, not sure how effective it will be with a live deployment due to latency and events potentially arriving to server out of order.

---

<div class="post-metadata">

**Author:** ![Michel\_Bujardet](https://forum.xojo.com/user_avatar/forum.xojo.com/michel_bujardet/32/252_2.png) [@Michel\_Bujardet](https://forum.xojo.com/u/Michel_Bujardet)\
**Post date:** [June 27, 2014, 5:03pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/6 "2014-06-27T17:03:57Z")

</div>

> [@104998:@Russ Lunn](#):
>
> any ideas how to stop it happening?

Ross, I have got it and it is sooo simple : click in the scrollbar does not trigger CellClick 😉

---

<div class="post-metadata">

**Author:** ![Greg\_O\_Lone](https://forum.xojo.com/user_avatar/forum.xojo.com/greg_o_lone/32/49_2.png) [@Greg\_O\_Lone](https://forum.xojo.com/u/Greg_O_Lone)\
**Post date:** [June 30, 2014, 4:06am UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/7 "2014-06-30T04:06:35Z")

</div>

Also, if you haven’t already, file a bug report.

---

<div class="post-metadata">

**Author:** ![system](https://forum.xojo.com/uploads/default/original/1X/455b4dcc0e61630e9f81940004ddffa49c432a46.png) [@system](https://forum.xojo.com/u/system)\
**Post date:** [October 29, 2020, 5:17pm UTC](https://forum.xojo.com/t/weblistbox-doubleclick-in-scrollbar-bug/17551/8 "2020-10-29T17:17:43Z")

</div>


