Trouble with formula.db

This WebDNA talk-list message is from

1997


It keeps the original formatting.
numero = 10905
interpreted = N
texte = In the invoice.tmpl we have the customer enter all the billing and shipping address information. In the final_invoice.tmpl we display the relevant information, costs, etc. and have a purchase button for them to hit.However, I cannot get the shipCost value to calculate from the formula.db.I have placed the exact same formula (below) in the final_invoice.tmpl page (to see that it does work) that I have in the formula.db for shipCost.[hideif [totalWeight]>0.5][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=half_lb][/hi deif] [showif [totalWeight]>0.5][hideif [totalWeight]>5][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=[math]ceil([ totalWeight])[/math]][/hideif][showif [totalWeight]>5][math][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=5]+(ceil([to talWeight])-5)*[lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=addl_lb][/ma th][/showif][/showif]If I place [shipCost] in the final_invoice.tmpl all I see is always zero. The above formula displays the proper costs in final_invoice.tmpl, but doesn't work in the formula.db, so what am I hung on?Curt ---------------------------------------------------------------------- | William Curt Eggemeyer Curt@mail.bzzzzzz.com | | BeeHive Technologies, Inc. | | http://www.bzzzzzz.com with a WebCam in Pasadena, California | ---------------------------------------------------------------------- Associated Messages, from the most recent to the oldest:

    
  1. Re: Progress !! WAS: Trouble with formula.db (Sven U. Grenander 1997)
  2. Re: Progress !! WAS: Trouble with formula.db (Grant Hulbert 1997)
  3. Progress !! WAS: Trouble with formula.db (Sven U. Grenander 1997)
  4. Re: Trouble with formula.db + more explanation (Grant Hulbert 1997)
  5. Re: Trouble with formula.db (Grant Hulbert 1997)
  6. Re: Trouble with formula.db + more explanation (w curt eggemeyer 1997)
  7. Re: Trouble with formula.db (Sven U. Grenander 1997)
  8. Re: Trouble with formula.db (Grant Hulbert 1997)
  9. Re: Trouble with formula.db (Sven U. Grenander 1997)
  10. Trouble with formula.db (w curt eggemeyer 1997)
In the invoice.tmpl we have the customer enter all the billing and shipping address information. In the final_invoice.tmpl we display the relevant information, costs, etc. and have a purchase button for them to hit.However, I cannot get the shipCost value to calculate from the formula.db.I have placed the exact same formula (below) in the final_invoice.tmpl page (to see that it does work) that I have in the formula.db for shipCost.[hideif [totalWeight]>0.5][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=half_lb][/hi deif] [showif [totalWeight]>0.5][hideif [totalWeight]>5][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=[math]ceil([ totalWeight])[/math]][/hideif][showif [totalWeight]>5][math][lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=5]+(ceil([to talWeight])-5)*[lookup db=country_cost_list.db&lookInField=country&value=[hideif [ShipToCountry]=Specify_Country][ShipToCountry][/hideif][showif [ShipToCountry]=Specify_Country][Country][/showif]&returnField=addl_lb][/ma th][/showif][/showif]If I place [shipCost] in the final_invoice.tmpl all I see is always zero. The above formula displays the proper costs in final_invoice.tmpl, but doesn't work in the formula.db, so what am I hung on?Curt ---------------------------------------------------------------------- | William Curt Eggemeyer Curt@mail.bzzzzzz.com | | BeeHive Technologies, Inc. | | http://www.bzzzzzz.com with a WebCam in Pasadena, California | ---------------------------------------------------------------------- w curt eggemeyer

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:

WebCat B13 Mac CGI -- Frames question (1997) WebCat2: Items xx to xx shown, etc. (1997) RE: Search (1997) A workaround for handling date range search in yyyy/mm/dd form (1997) Search returns all, not 20 (1997) Bug or syntax error on my part? (1997) TEXTAREA and sendmail (1998) Help name our technology! I found it (1997) [WebDNA] a major shift in strategy? (2008) WebCat hosting providers? (1997) WebCat2b13 Command Reference Doc error (1997) Not really WebCat (1997) Only charge card when product shipped ? (1997) (1997) listfiles-looking for slick solution (1997) webcat NT (1998) [movefile] (1999) Adding discount to cart (2000) PCS Frames (1997) Error -108 (1997)