Have you defined the dimension of AddressData as 5?
You should have Dimension as 5 in this case, check in C/AL Globals, select your variable AddressData, go to Properties (Shift + F4) and check the value of Dimension.
If AddressData is a string, then each letter in that string is a character. You access these characters using standard array notation, AddressData[index]. Essentially you are trying to store a text value in a spot that can only hold one character.
Changing the dimensions on the variable will solve this. In that case the first index you provide refers to the index of the array, while the second optional index refers to the character in the string.