You closed the procedure and the "if then" block just fine, you were just missing the semi colons, that's all. Glad it worked out!