Can I keep loops running after switching profiles?

Can I keep loops running after switching profiles?

Having buttons held down is good, but to have this effect for scrolling I need to use a loop. I put these kinds of commands in a sub-profile, leaving my main one for quick single actions and default mouse buttons.
I then hold down an unused button to temporely switch to this subprofile, press the desired macro, and let go.
This works wonderfull for my desktop profile, but now that I'm mkaing a profile for Minecraft, I encounter this problem. I might need to use multiple inputs on one button, but I haven't figured that out or if it will help me.