|Do the values in W2!A1:A20 contain strings that are longer than the 10 characters you are searching for?|
If so, try this:
=INDEX(W2!$A$1:$A$20, MATCH(LEFT($A$1, 10 ) & "*", W2!$A$1:$A$20, 0))
If W2!A1:A20 contain only 10 character strings, then you don't need the & "*".
MATCH will return the relative position of the value you are searching for from the Range specified - W2!$A$1:$A$20
LEFT($A$1, 10 ) & "*" tells MATCH to find the first 10 characters of A1 even if the cells in the range were are searching contain more than 10 characters.
INDEX returns the value from an array based on the row_num and column_num arguments. The row_num argument is provided by the MATCH function. We don't need column_num argument because the range is only 1 column wide.