Fix Button Click Action

I have an an input element and a button on a page. The button is initially hidden and appears when the input value is no longer empty. My workflow for this is: “When the button is clicked, open an external page.”

However, if the user hits “Enter” after they enter a value into the input, and the user does not click the button, the external page is still opened. Thus the workflow runs as if the button were clicked. How can I fix this so that if a user hits “Enter” the Button Click workflow is not run?

Hey @R.Galbraith :slight_smile: I tried to recreate this but when I hit enter, the external website from the button workflow wasn’t opened (it only opened when I tabbed from the input to the button and hit enter). Can you share a link?

Haven’t tested this to reproduce what you’re experiencing, but you can try adding a condition to the Enter button click event so that it only runs when the input is visible.

Thanks for your replies @fayewatson and @romanmg. I fixed it. In my workflow for the page, the original event was: “Do When Input’s value is not empty” > Show Button.

I changed the event to: “When Input’s value has changed and Input is not empty” > Show Button. This somehow fixed the issue. Now, if I hit ‘Enter’ after typing my input, the button click event is not triggered. The Button Click now works only when its clicked.

It’s fixed but I don’t know exactly why. Moving on now.

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.