Sorry, didnāt notice that. The gist of it is in this quote from the thread:
āThe event handling code runs whether or not a component is enabled. In your logic for the event handler you should check to see if itās enabled or disabled and branch from there.ā
As Jordan mentioned, the script behind the buton has to explicitly evaluate the enabled condition if you are using that property. Otherwise, I think the only thing it does is make the button look greyed out.
And again, for troubleshooting, be liberal with print statements and turn java logging on. This canāt be stressed enough, in my humble opinion.
Just to avoid any confusion, only the mouse events continue to function when the component is disabled, and the reason they do so is explained in the referenced post from above.
The actionPerformed event (which is where the current script in question is located) will not fire when the component is disabled unless you call a doClick() on the button from scripting.
This is why this problem is confusing. I'll continue to take a closer look and try to figure out what's happening.
Would checking for the enabled state at the beginning of the script be a possible workaround until a root cause is determined? At the very least, it shouldnāt hurt anything.
It may and it may not and it surely wouldn't hurt anything, but there already is a workaround in place. There are no longer erroneous entries being written. Here we are merely logging any attempts to write that are occurring when we shouldn't be writing and trying to figure out why these are happening.
I have removed the binding on the enable of both buttons. I am now setting it with code from the Pin box. We will just have to see if this works better.
Do we have an ETA on when this āFeatureā may be fixed?
Go ahead and put up the new project just so we have the most recent version.
Unfortunately there is no way that we can have an ETA on a fix until we can figure out what's wrong and some way to consistently replicate it. We'll continue looking into it to see what could possibly be happening.
Well good news. I had no entryās in the tbl_admin today.
I set the code to look if they are clocked in and then enable/disable buttons. If they did manage to get punched in twice it would write to the tbl_admin table and then clock them out of both.
I removed the code from the enable on the buttons to the property change on the Pin box. BDI_Time_Clock (2011-05-04).proj (68.1 KB)