Thanks for that, leo, but I already have buttons for removing a certain number of characters. No I want to rename leaving a certain number of characters. As I mentioned, I already tried that and ran into problems. Even with help from jon something didn't work with the nested curly brackets and I decided not to follow that road any further.
Instead, my question pertains to the structure of rename scripts and what code is allowed in the global/initialization part of the button.
Thanks,
MartO