Mart,
What if the file looks like
 Code:
11;AA22;833;AA;44;5CF5
22;XX58;233;BB;ZZ;0AA0

I think you better split the lines on the ";", AScan the array for an exact "AA" match and join the array using ";" as delimiter.