Hi @mars,
This tutorial might be useful:
I need to note, however, that it will not protect against clicking one button very rapidly - the visibility may not work very fast.
So probably it would be good to add the same logic to the button action as well (create only if no record exists).
Hope this helps!