Thanks. I am new at Excel Macros. I was using Excel functions to do this. Canyou tell me the macro for this problem.