It doesn't happen to me much anymore (phew) but if it does I try and find somewhere quiet, I sit down and I breath and I do some positive self talk "this can't hurt me..it's only a symptom of anxiety" I keep repeating that mantra until my heart rate goes down.
I also keep my anti-anxiety meds with me. If I have a whopper of an attack/heat rate jump I am not ashamed to take my medication. Thankfully, as I said it doesn't happen often.
If it happens when you are driving..pull over! Have you done any work on affirmations?? I always keep a few up my sleeve so If I am terribly stressed I can repeat them to myself and hopefully stop my anxiety from getting worse. I hope this helps you a little
Panic Attack Survivor