I was playing with alignment parameters earlier today, and noticed that when it aligns the block to something, it actually changes the rotation angle of the block. In other words, there aren't any properties associated with the alignment parameter, like there would be with, say, a rotation parameter. I can't check now, but I would guess that blocks with only alignment parameters don't need to be assigned anonymous names, since they don't really have any dynamic properties, just an automatic rotation.
Don't know if that would have anything to do with why your code isn't working, but hope it helps anyway.