I created a macro that does just this, a long while ago. Let me see if I can find some time to track it down and see if it still works / clean it up some.
If you are not a VIP member of MQ2 you should consider donating $10-$20 to the MQ devs to show your support for the hard work maintain the core MQ source.