Hi All,

Following on from https://www.excelforum.com/excel-pro...orksheets.html

DMAValue As Long
DMAValue = InputBox("Enter the DMA number to work on")
    If ArrIN(i, 10) >= DMAValue & 000 And ArrIN(I,10) <= DMAValue & 999 Then

I am having trouble with If criteria. The user is prompted to enter a number between 1 and 17 in the input box . I then want the code to search for 1000-1999 for "1", 2000-2999 for "2" etc. I have tried to do this as 'DMA Value + the 000 or 999 to make up the numbers but it's not working. Any thoughts?