Utilizing Profile w/Procedures - Introduce Delay

Sorry if this is the wrong place to post this, let me know if i should post somewhere else.

I have created a Profile to run two procedures. One is to download a certificate to a local PC and the other procedure is to install the certificate. What I am noticing is that sometimes this works, and sometimes this doesnt work, and one reason I believe this is is because the 2nd procedure runs before the 1st procedure is fully complete.

Is there an angle where I can make sure the 1st procedure is complete before the 2nd procedure runs?

Maybe the easiest way to do this would be to introduce a time delay after the 1st procedure. Could someone help me with code that will introduce a time delay (some type of loop maybe?) of lets say a minute before the procedure ends?

You can use a different approach here @sromine. Instead of running two procedures, just use one to accomplish your objective of downloading the certificate and then installing it. You create first a batch (BAT / VBS / Powershell) file and then utilize the appropriate predefined procedure (Run a BAT / VBS / Powershell command) to run it on the target endpoint(s). The ‘delay’ part will all be in the BAT / VBS / Powershell file.

Being able to have this work without additional scripting would be much nicer