Why write more code than necessary?
"_X moveInCargo NAME" forEach units this
That's all you need. A group is by defenition named after the leader. If the leader of a group has Alpha in his Name field, the group will be called Alpha. At least when refering to it in a script, or init spell.
And using "this" will do the work as well. I know this works since it is how I always do it.
Cheers, KTottE