What's the formula? What does the rest of the code look like? Can you post a sample workbook?

Regards, TMS