Patel45, When I ran the code I managed to get random numbers without 3 consecutive numbers in sequence. It didn't quite appear right as some numbers may be in pairs such as 5-6 or 12-13 etc. I allowed pairs but not 3 or more consecutive numbers. I tried modifying your codes using And,Cells including changing Number > 2 but without success. Thank you for your patience.