Well, there is more work to do here, as I have run into the problem where I am not alwyas grabbing the correct 3 lines. I will post a solution once I get it complete...I have a few ideas, I will just have to delve into my perl books to see how to implement that bit I think...hmmmmmmm