This is all Dan’s script and it shows the countdown before every auto-save. The main function here is HRnet.Form.UI.Buttons.Save.doClick(); that does save the data, the rest of the code is count-down and displaying.

So if you don’t need any of this, you can just call HRnet.Form.UI.Buttons.Save.doClick(); whenever you need, or on timer:

This would click Save button every five seconds.
I believe this would not work in a workflow, as you can’t save the workflow – you need to submit the workflow and that can happen only once. And would really you want to submit the workflow many times, when you have some complex logic behind it (i.e. send email to everybody in your company)??