What is the correct way to determine if a map element exists?
For example, the isDefined() test generates an "Array subscript out of bounds" error:
_Lst = `Ann,1` :@TAB: `Bob,2` :@TAB: `Carl,3`
_map = MapCreate(_Lst)
if isDefined(_map[`Bob`])
message(`Bob is in pos`, _map[`Bob`])
endif
if isDefined(_map[`Fred`])
message(`Fred is in pos`, _map[`Fred`])
endif
MapKeyExist (https://docs.winbatch.com/mergedProjects/WindowsInterfaceLanguage/html/MapKeyExist.htm)
I'm going with: "that wasn't in MY copy of the help file when I looked at it yesterday..." But it's there now. Spooky. Mandela effect?
Thanks Tony.
Man, if I had an extra minute of life for every hour I've spent searching for something that is right under my nose (and often not finding it)... I'd live forever.
My wife calls it refrigerator blindness...
I appear to be nearly blind to my own typos. It's a bummer.
Quote from: td on May 18, 2024, 03:37:37 PMMy wife calls it refrigerator blindness...
I first heard that term in a comedy routine by Rita Rudner.
She's great. I love her.