Re: if then ....

This WebDNA talk-list message is from

2004


It keeps the original formatting.
numero = 57831
interpreted = N
texte = Else is NOT needed, also change your if statement to have 2 (( and )) like: [if (("[setCurrency]"=3D"JPY") | ("[setCurrency]"=3D"EUR") | ("[setCurrency]"=3D"USD"))] Then it should work as expected. Nitai On 14/5/04 2:35 PM, "Alan White" wrote: > Hi >=20 > Can anyone tell me if I *have* to use "else" in an if statement? I have = the > following code but the else is redundant. >=20 > [!] -- Check for currency switch -- [/!] > [if ("[setCurrency]"=3D"JPY") | ("[setCurrency]"=3D"EUR") | > ("[setCurrency]"=3D"USD")] > [then] > [!] -- Set New Currency -- [/!] > [writefile conversionsFolder/[cart].txt] > [raw][text]currency=3D[setCurrency][/text][/raw] > [/writefile] > [/then] > [else] > [/else] > [/if] >=20 > [!] -- Get Currency -- [/!] > [include file=3DconversionsFolder/[cart].txt] >=20 > Any revisions are welcome although it does what it says on the box... >=20 > Cheers > Alan >=20 >=20 > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ >=20 --=20 Tools to energize your business Web Content Management =ABRedakto=BB & eBusiness Systems ComputerOil=AE AG Dammstrasse 7 5400 Baden / Switzerland Telefon +41 (0)844 44 55 66 info@computeroil.com http://computeroil.com ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: if then .... ( Alan White 2004)
  2. Re: if then .... ( "Nitai @ ComputerOil" 2004)
  3. if then .... ( Alan White 2004)
Else is NOT needed, also change your if statement to have 2 (( and )) like: [if (("[setCurrency]"=3D"JPY") | ("[setCurrency]"=3D"EUR") | ("[setCurrency]"=3D"USD"))] Then it should work as expected. Nitai On 14/5/04 2:35 PM, "Alan White" wrote: > Hi >=20 > Can anyone tell me if I *have* to use "else" in an if statement? I have = the > following code but the else is redundant. >=20 > [!] -- Check for currency switch -- [/!] > [if ("[setCurrency]"=3D"JPY") | ("[setCurrency]"=3D"EUR") | > ("[setCurrency]"=3D"USD")] > [then] > [!] -- Set New Currency -- [/!] > [writefile conversionsFolder/[cart].txt] > [raw][text]currency=3D[setCurrency][/text][/raw] > [/writefile] > [/then] > [else] > [/else] > [/if] >=20 > [!] -- Get Currency -- [/!] > [include file=3DconversionsFolder/[cart].txt] >=20 > Any revisions are welcome although it does what it says on the box... >=20 > Cheers > Alan >=20 >=20 > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ >=20 --=20 Tools to energize your business Web Content Management =ABRedakto=BB & eBusiness Systems ComputerOil=AE AG Dammstrasse 7 5400 Baden / Switzerland Telefon +41 (0)844 44 55 66 info@computeroil.com http://computeroil.com ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ "Nitai @ ComputerOil"

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Webcatalog 2.1* and Personal Web Server 4.0 (1998) shipcost and Formulas.db (2000) total number of matches (1999) Requiring that certain fields be completed (1997) Nested tags count question (1997) Passing [quantity] (2000) Problem displaying search result (1997) displaying New products (using [date]) (1997) WebCat2b13MacPlugIn - [include] doesn't allow creator (1997) webcat2b12 CGI -- Date comparisons (1997) Date conversion (2002) RE: completed orders database (1997) WCS Newbie question (1997) Not really WebCat (1997) resorting found set (2005) problem with applets embedded in tpl files (1997) Template Encryption (1998) Emailer setup (1997) [SearchString] problem with [search] context (1997) What about an ends with operator? (2000)