but depending on your needs, you might want to do it differently. It is just a matter of figuring out what criteria you want to apply and then figuring out how to implement those criteria. Nick PS Is there a better way to get the original buffer name?