Hey, The code works great but I need it to work before excel is closed, so when I put the code in the before close section in VB, I get an error, any ideas?