You need to split the post codes by comma then go one by one and look for a match.
Code would look like this:
Dim strPostCode, strInput, x
Dim arrPostCodes, curPostCode, blnFoundMatch
strPostCode = "HS1,HS2,HS3,HS4,HS5,HS6,HS7,HS8,HS9,IV41,IV42"
strInput = "HS24AB"
arrPostCodes = Split(strPostCode, ",")
blnFoundMatch = False
For x=0 To UBound(arrPostCodes)
curPostCode = arrPostCodes(x)
'If Left(strInput, Len(curPostCode))=curPostCode Then
If InStr(strInput, curPostCode)>0 Then
blnFoundMatch = True
Exit For
End If
Next
Erase arrPostCodes
If blnFoundMatch Then
'match found, do something...
End If
The above will look for each post code anywhere in the user input e.g. "4AB HS2" will also return a match; if you want the post code to only appear in the beginning of the input, use the alternative If
line that is remarked in the above code.