what exactly are you trying to do - what type of text file etc - have you thought of writing a macro in pfe and calling that from within a sub????