Re: Shipping Formula %

This WebDNA talk-list message is from

2003


It keeps the original formatting.
numero = 47474
interpreted = N
texte = Your 90% of the way there!I dunno 4.5 code (use v3.07) but after looking at manual it would be like thisI suppose you would put this in place of old code in the fomulas.db for shipCost You might have to put it all on one line ie: get rid of all the carriage returns and spaces (I just used then just for code flow)[if ([subTotal]>0.00) & ([subTotal]<499.99)] [then]shipCost *.20[/then] [else] [if ([subTotal]>500.00) & ([subTotal]<999.99)] [then]shipCost *.18[/then] [else] [if ([subTotal]>1000.00) & ([subTotal]<1499.99)] [then]shipCost *.12[/then] [else] [then]shipCost *.12[/then] [/else] [/if] [/else] [/if] [/else] [/if] -- Regards, Marko ------------------------------------------------------------------ Marko Bernyk - Senior System Engineer mailto:marko@conexus.com.au  http://www.conexus.com.au Technical Services, Conexus Pty Ltd, Sydney, Australia Ph 02 9975 2799 Fax 02 9975 2799          :) ------------------------------------------------------------------On Thursday, 6 February 2003 11:03 AM, Sales wrote: > I see from the documentation how to figure shipping using a fixed >percentage: > >shipCost *.15 (in >Formulas.db) > > So how would you write a formula using a floating discount schedule >like this? > >Example: >if subTotal is between $0.00 and $499.99, then shipCost = subTotal * >20%, >if not then if subTotal is between $500 and $999.99, then shipCost = >subTotal * 18%, >if not then if subTotal is between $1000 and $1499.99, then shipCost = >subTotal * 16%, >otherwise shipCost = subTotal * 12% > > If someone could someone show an example (preferably in the XML >syntax, but if not, that's O.K) of nested If statements using the above >info, I'd greatly appreciate it. > >Thanks, >Marc > >*--*--*--*--*--*--*--*--*--*--*--*--*--*--* >Superior Shelving Systems >P.O. Box 6949 >Tacoma, WA 98406 > >253-756-8138 >253-752-1610 fax > >http://www.SuperiorShelving.com > >The Storage Shelving Specialists >Since 1984 >*--*--*--*--*--*--*--*--*--*--*--*--*--*--* > > >------------------------------------------------------------- >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/ >------------------------------------------------------------- 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: Shipping Formula % (Marko Bernyk 2003)
  2. Re: Shipping Formula % (Rob Marquardt 2003)
  3. Re: Shipping Formula % (Donovan Brooke 2003)
  4. Re: Shipping Formula % (Sales 2003)
  5. Re: Shipping Formula % (Marko Bernyk 2003)
  6. Shipping Formula % (Sales 2003)
Your 90% of the way there!I dunno 4.5 code (use v3.07) but after looking at manual it would be like thisI suppose you would put this in place of old code in the fomulas.db for shipCost You might have to put it all on one line ie: get rid of all the carriage returns and spaces (I just used then just for code flow)[if ([subTotal]>0.00) & ([subTotal]<499.99)] [then]shipCost *.20[/then] [else] [if ([subTotal]>500.00) & ([subTotal]<999.99)] [then]shipCost *.18[/then] [else] [if ([subTotal]>1000.00) & ([subTotal]<1499.99)] [then]shipCost *.12[/then] [else] [then]shipCost *.12[/then] [/else] [/if] [/else] [/if] [/else] [/if] -- Regards, Marko ------------------------------------------------------------------ Marko Bernyk - Senior System Engineer mailto:marko@conexus.com.au  http://www.conexus.com.au Technical Services, Conexus Pty Ltd, Sydney, Australia Ph 02 9975 2799 Fax 02 9975 2799          :) ------------------------------------------------------------------On Thursday, 6 February 2003 11:03 AM, Sales wrote: > I see from the documentation how to figure shipping using a fixed >percentage: > >shipCost *.15 (in >formulas.db) > > So how would you write a formula using a floating discount schedule >like this? > >Example: >if subTotal is between $0.00 and $499.99, then shipCost = subTotal * >20%, >if not then if subTotal is between $500 and $999.99, then shipCost = >subTotal * 18%, >if not then if subTotal is between $1000 and $1499.99, then shipCost = >subTotal * 16%, >otherwise shipCost = subTotal * 12% > > If someone could someone show an example (preferably in the XML >syntax, but if not, that's O.K) of nested If statements using the above >info, I'd greatly appreciate it. > >Thanks, >Marc > >*--*--*--*--*--*--*--*--*--*--*--*--*--*--* >Superior Shelving Systems >P.O. Box 6949 >Tacoma, WA 98406 > >253-756-8138 >253-752-1610 fax > >http://www.SuperiorShelving.com > >The Storage Shelving Specialists >Since 1984 >*--*--*--*--*--*--*--*--*--*--*--*--*--*--* > > >------------------------------------------------------------- >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/ >------------------------------------------------------------- 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/ Marko Bernyk

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:

More on the email templates (1997) [format 40s]text[/format] doesn't work (1997) Image upload *CODE SAMPLE* (2000) Webcat no longer supported? (2006) [WebDNA] Processor usage off the charts (2008) OFF TOPIC: help wanted (1997) WC2b15 File Corruption (1997) controlling user input (1998) Emailer (1997) Problem with version 4 browsers (1998) mail sent from webcatalog. accented chars! (1998) Problem (1997) Security Issues and WebCommerce Solution (1997) [WebDNA] v7 Stress Test and Strange Behaviour (2012) Searching for all records (1998) OH CRAP!!!!!- Template not found error!!! (1999) Tiny Store / Checkboxes (1998) Re[2]: Problem with new formvariables (2000) Word Break (1999) Separate SSL Server (1997)