Is there a way for me to implement something like a global onClick method. What I’m trying to do is run a method for every click a user makes without having to write calls into every existing onClick method I already have. The issue is that our solution is so large and while we have some general methods that half of our buttons, links, etc. call by default there are still the other 50% of items that have custom methods assigned to them. I need to be able to run a specific method AND still process the existing onClick method that is assigned to an element.
maybe with the webclients utils plugin you could generate a callback to a function and that callback you attach to a specific div in the browser.
I am not sure if then both clicks are called when you press a button that is inside that div that already has a onaction…
Thanks Johan. I’m actually looking for something global, meaning every click the user makes without having to add this to specific items.
I found a solution that works for what I’m trying to do though. For our solution, every form we have extends one base form we call frmCore. So, in the frmCore onShow method I perform the needed actions, in turn, every form that is shown now logs to our tracking database allowing me to capture a users history through our application, not just the audit tracking of database changes, but also what they are actually viewing and how long they spend on each form. Perhaps something along these lines (user history tracking) is something that could benefit the larger Servoy community and could become an enhancement in a future release.
Hope this helps others looking for something similar.