Help ! I'm searching for the unequal if statement!
This
if (a != b) then
of
if (a <> b) then
is not working, what is the correct way of doing this?
Thanks.
Unequal if statement?? != or <>
Moderator: leecollings
-
rgroothuis
- Posts: 347
- Joined: Friday 03 April 2015 17:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
-
rgroothuis
- Posts: 347
- Joined: Friday 03 April 2015 17:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Unequal if statement?? != or <>
I think I finally found my own answer
This is not something that is widely used.
The solution is:
if (a ~= b)
Please note the above ~ is NOT the - (minus) character.
The solution is:
if (a ~= b)
Please note the above ~ is NOT the - (minus) character.
- nayr
- Posts: 354
- Joined: Tuesday 11 November 2014 18:42
- Target OS: Linux
- Domoticz version: github
- Location: Denver, CO - USA
- Contact:
Re: Unequal if statement?? != or <>
If you didnt find it, here is the specific doc you were looking for, there are a lot more worth looking through, lua is unique enough to be maddening sometimes..
http://www.lua.org/pil/3.2.html
http://www.lua.org/pil/3.2.html
Debian Jessie: CuBox-i4 (Primary) w/Static Routed IP and x509 / BeagleBone with OpenSprinkler / BeagleBone Planted Aquarium / 3x Raspbery Pi2b GPIO Slaves
Elemental Theme - node-domoticz-mqtt - Home Theatre Controller - AndroidTV Simple OSD Remote - x509 TLS Auth
Elemental Theme - node-domoticz-mqtt - Home Theatre Controller - AndroidTV Simple OSD Remote - x509 TLS Auth
Who is online
Users browsing this forum: No registered users and 1 guest