See the dynamic commands script I posted today.