I've run into this, too. There's currently not a function for getting the object name of the button clicked.
An alternative I've used, though, is to have the "button" actually be a field with an onObjectEnter trigger. Since the user has clicked into the field, that field is now the "active" object, and you can get it's name, then leave the field. If you have a background image fill on the field, the difference visually is pretty negligible.
To be honest I think it would make things harder, what would the function "Get ( ActiveLayoutObjectName )" parse as result if the button-objectname now is the activating object? How do you determine which object is active at the time the button is clicked? I prefer to use the scriptparameter to parse an array of parameters, including a name for the function i wish to call with the button.
Thanks both for your effort and time.
I am using the new "menu bars" from FMPA 14. (Works great).
So, the option to use a field that acts like a button won't work in this case. (Not when using the menu bars).
If you click a button, the button always does what it has to do (e.g. run a script), even when the button is not active. If a certain field is active, and you click a button, the button performs it's script, but the field stays active. So if you use Get (ActiveLayOutObjectName) you get as result the name of the active field (or active other button), but not the button you clicked on.
So, I will use Scriptparameters, a little more work, but no disaster.