[Gambas-user] Example to IIF: what is meant here

Jussi Lahtinen jussi.lahtinen at ...626...
Wed Oct 10 16:20:41 CEST 2012


> Print ("you have ") & X & iif(x>1, ("message"), ("messages "))
>

This is still not good. Better would be:

Print Subst(("you have &1 &2"), x, IIf(x > 1, ("messages"), ("message")))

Now translation is not depended on order of words.

Jussi



More information about the User mailing list