And it is correct that it doesn't work. The token you would get with your comparison would be the filename without extension.
example.png
has two tokens if the seperator is ".": "example" and "png"
Looking for the first token (index = 1) would only be true if you'd compare to "example"
Looking for the second token (index = 2) would only be true if you'd compare with "png" (and not ".png", the dot is the seperator of your tokenized list)
This should work:
+ System: GetToken(File.CurFile, 2, ".") Equal to "png"
EDIT:
It only works with normal filenames! For example, if the filename is "somepicture.jpg.png" then you would need to compare against the third token.
A better working way for you is
+ System: GetToken(File.CurFile, NumTokens(File.CurFile, "."), ".") Equal to "png"
This will always look at the last extension of a file's name.