Forcing string comparisons, or When is "0" not 0?

Devin Asay devin_asay at byu.edu
Wed Oct 14 17:10:05 EDT 2015


> On Oct 14, 2015, at 2:39 PM, Paul Dupuis <paul at researchware.com> wrote:
> 
> if fld "Display" contains "." then
> 
> of if you're just concerned with it ending with "."
> 
> if fld "Display ends with ".” then

Yeah, that works, but then I end up with a mess like this:

  if fld “display” = 0 AND NOT fld “display” ends with “.” then … 

But this may be what I have to go with. That’s at least *sort of* comprehensible to a newbie.

I'll have to explain to them that “LiveCode tries its hardest to make something into a number if there is any chance at all that it could be a number, so we have to do an extra check to make sure it’s not this specific type of numeric expression that happens to end with a dot.”
:-/

Devin

Devin Asay
Office of Digital Humanities
Brigham Young University



More information about the use-livecode mailing list