This is not as hard as you may think. First is this a pre-programmed button or not? I will tell you how to do it from scratch.
On a blank button move the ir code that you need to do this record. On the button you want to have this macro, click the record icon in the macro window, then goto the ir code that you needed and click on it 2 times. Stop the recording and click on the icon that looks like a clock with a + sign on it, this will bring up a window for the delay settings. Click on the 5sec or what ever delay you need. Left click and hold on the delay in the macro and move it between the 2 ir codes.
It you did everything correct you should be able to download to the remote and should work.
P.S. I would make this command a push and hold button. That is the "if" in the macro window and double click on the "if (true)" line in the window and that should bring up the "if setting " window and click on the ">=" in the first drop down and "2" or more in the second drop down and then "ok" . This will let you do what you wanted but you wont activate the "record" when you did not want to.