Is it possible to make a button work only once?

I have 5 buttons that are controlling a progress bar and I wanna make each of them possible to be clicked only once. Doesnt matter what order.

You just need to store the fact the the button has been clicked once, and don’t allow it to be clicked again after that.

where do i do it? data? workflow? button’s conditional? progress bar’s conditional?

Where do you do what? Store data?

Well that depends on what you’re trying to do and how your app works…

You could use a custom state, session or local storage, the Bubble database, or some external database… again, depending on what exactly you need.

Then just use that data to determine whether the button can be clicked (or whatever specific UX you need).

If you’re not sure how to work with data in Bubble, then I’d recommend starting at the very beginning, reading through the manual, and doing some of the basic tutorials.

I’ve read through the manual and I’ve done tutorials mate, I just wanna know where can I change the abilty to click each button only once. Basicly you click it and then it changes color or whatever and so when you try to click it again it wont work

I’m not sure what else to tell you…

You just need to store the data, then use that data as the basis for your conditions…

I can’t really tell you any more than that as I don’t know anything about your app, where you’re storing the data, or what you’re trying to do soecifically

But feel free to share more info if you like more help with this.

I want to make button ‘1h’ inactive after its been pressed then ‘2h’ and so on
(rn I can press button ‘1h’ multiple times and the bar will add 20% each time I press it)

Well, as I said you just need to store the fact that it’s been clicked, and then set a condition on the button to make it unclickable when that data shows it’s been clicked.

Where you store that data will depend on what you’re trying to do here (which I still don’t know), but if there’s no need for this to persist beyond a page refresh then just use a custom state.

If you need it to persist beyond page refresh then you’ll need to use some more persistent storage (such as local or session storage, or a database) but again, that will depend on what you’re actually trying to do.

So which is it you need?

im storing the data in a database

Then simply use that as the basis for your conditions on the buttons - i.e. when theDataInQuestion’s value is relevantValue this button is not clickable