# Is there a true random?

**URL:** <https://forum.kirupa.com/t/is-there-a-true-random/241163>\
**Category:** Uncategorized\
**Created:** [October 10, 2007, 4:56pm UTC](https://forum.kirupa.com/t/is-there-a-true-random/241163 "2007-10-10T16:56:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Xannax](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/xannax/32/3350_2.png) [@Xannax](https://forum.kirupa.com/u/Xannax)\
**Post date:** [October 10, 2007, 4:56pm UTC](https://forum.kirupa.com/t/is-there-a-true-random/241163/1 "2007-10-10T16:56:53Z")

</div>

I have this very weird bug;  
I have a page, PageItems. It contains thumbs (instances of thumb class), and a display to load the pictures that are pre-loaded and cached by the thumbs. Now, from time to time, when i click on a thumb, instead of showing the picture, flash outputs:

```auto

ReferenceError: Error #1069: Property showImage not found on lib.pages.PageItems and there is no default value.
    at lib.pages::PageItems/mouseUpHandler()

```

the showImage being a function of my thumb class.

But most of the time, it works: when I click a thumb, flash displays the image, and everything works as expected. Only one time out of ten, I get this error, and I can not figure out how to reproduce it in order to understand where it comes from. I just click randomly on the thumbs, sometimes for thirty seconds, sometimes from the first click, to get this.  
If I output the event.target.parent, I sometimes get the thumbnail name (normal, as expected), and I sometimes get the PageItem (which doesn’t even have an eventListener for mouseclicks, by the way). For the same click on the same spot.  
I don’t understand. Anyone had a similar problem? Anyone has an idea on how to handle this? The only thing I could think of is to check the event.target, and if it “PageItems”, I cancel the event. So, one time out of ten, the user will find nothing happens when he clicks on a thumbnail. That’s surely not the most elegant way to do it.

Any help would be appreciated.
