Aha! Thanks for saving me frim bashing my head against the wall on this one.
The current goal is to rename and redefine a series of block definitions that were created incorrectly through another function, so I believe your approach should work provided I define any needed blocks before hand.
In the other function, the user uses a dialog box to lookup and display information for our joint definitions pulled from a database. Once the user finds the selection they want, they can then insert that specific joint block, with a definition consisting of the JT number, a part reference, and all other info stored as invisible characteristics so any given insertion could be confirmed to be accurate by using the BATTMAN command. Due to a bug that was discovered after a limited release, many of the block names/part references were incorrect. We found that the attribute data was always correct, so I was trying to write a quick routine that could fix the layouts containing the incorrect blocks leveraging the attribute data within them.

Part of the code I posted here is related to the "refresh" portion of the above, where it forces all generated block definitions to adhere to the current standard + data. This is why there was that floating Gstart variable; that's being used for a time elapsed display once the refresh is completed. Sloppy editing on my part.