It's a bug in your code I'm afraid

( EDIT - no it's not

). I've rearranged the IF statement as I don't like single line IFs.
Code:
If FileExist(FN) Then
mapslist.Item(ind) = FN <font color="Red">' Error! assigning a string not an image</font>
Else
mapslist.Item(ind) = mapslist.Item(0) <font color="SeaGreen">' OK, this is an image assignment</font>
End If
This works in the IDE because the assignment checks if a string is being assigned and reads the bitmap from the file if it is a string. The optimising compiler just does the assignment without checking.
EDIT:-

I've just looked at the help for ImageList.Item and it states that what you are doing should work so it looks like a compiler bug.