Thanks a lot Richi007, that worked. But I was wondering why a wait instruction is required. and why I need to save them. I always save them but as a good programming practice to improve the readability, but in this specific case why do I need to do that.