Thanks everybody for your replies... I have it sorted out now. I was trying to make it more complicated than it was.