It seems that the OP has decided that your formula works and has now marked the thread as solved.