Forum Documentation Showcase Pricing Learn more

Make Loops in Bubble


#1

Hello Bubblers,

I see on Bubble is almost impossible making a loop: I tried to do it with custom events repeating each other, but in the debug mode I see it declear it as error, and it get stuck.

There are no other way to do what I am trying to do, I need a loop to make Bubble check some “things” using an API, and it won’t stop until it find the right response from the API.

Is it really impossible to do?


#2

Check this out


#3

Thank you very much.

So I need to make an API workflow, right? Can I do it before paying for a subscription?


#4

no, you need subscription


#5

@neerja, maybe it’s an idea to expand the pricing overview with a row for API workflows.

On https://bubble.is/pricing there is no mention of the API workflow restriction.


#6

I don’t think this is the solution.

I need a loop only when the user clicks on a button, it isn’t a scheduled loop.


#7

“Scheduled” can also mean to run once on button click.


#8

I did it with a scheduled trigger event. It works as expected.
That’s strange anyway.

And what about server capacity? For a personal plan would it run fluently with 300 users?


#9

It’s no problem.

Not an optimal environment to do loops, but it’s totally simple.

If you’re stuck drop me a line,

Sincerely,

Ashley


#10

I have taken the time to learn plugins. In Javascript you can loop to your heart’s content and get the answer in a jiffy. (sorry for the English colloquialisms). Doesn’t work for everything, but can be handy for lots of situations.
I’ve written some beginners guides to plugins to get you going!


#11

You can use the repeated every x seconds to implement loops here.

for example, you could press a button to trigger the “do something every x seconds”.

Set the X to .01 seconds. (Of course Bubble ain’t gonna serve you up 100 operations a second, but it doesn’t hurt to ask. I haven’t clocked the speed of iteration but it’s pretty quick. If you need something speedier than the templated universe that is bubble, dig into a plugin or run something in an HTML window.

Anywho, Drop me a line if you have more trouble with while loops, for loops, or iteration in general.

It’s quite simple here with the tools that Bubble hath bestowed upon the net.

Happy Bubblin’!

ashley