Hi Chris
Thank you for your help, I have got it working now. I think the fact that the "Save As..." dialog box was not showing as a separate icon in the taskbar when I was debugging might have given me the impression that the code was hanging.
Thank you again
Brendan