Thanks GMayor, I tried replacing the code but with no effect, it exits the word file and keeps the same name.