June 5, 200322 yr Newbies I guess this isn't a script but a formula question. I'm fairly new to Filemaker though so I am not sure. I need to write a formula for a shipping rate calculation based on weight. The starting rate for anythin 1 lb or under is $5.95. I need to add $.50 per additional lb over that. The following is what I have so far: If (ShipMethod = Ground and TotalWeight <= 1,5.95,If (ShipMethod = Ground and TotalWeight > 1,5.95 + .5)) I am stuck on the adding .50 per additional lb. Any help would be much appreciated. Thank you.
June 5, 200322 yr Hi Al, You need to add a couple of Fields, I've enclose a simple demo file for you. HTH Lee ShipingWieghtPlus.fp5.zip
June 5, 200322 yr Author Newbies Thanks Lee. The calculation only seems to work once though (it adds the initial .50 for being over 1lb but it doesn't add another .50 for over 2 lbs) less than or equal to 1 lb = $.5.95 less than or equal to 2 lb = $.6.45 less than or equal to 3 lb = $.6.95 (doesn't work) Thanks again.
June 5, 200322 yr Case(ShipMethod = Ground, 5.95 + ((Round(TotalWeight + .49, 0) - 1) * .5)) We add .49 to the weight so that it will round up.
June 5, 200322 yr Hi Al, Tom's is a much smooter calculation than my approach. Use his. You are correct about it not increasing The calculation for "AddCostCalc" needs to be changed to: Case(Lbs <= 1.0, 0, Lbs> 1, Lbs * .50) Sorry, Lee
June 5, 200322 yr I notice a couple of things about these two approaches. 1). Tom's calculations adds .50 for for each 1 pound increment greater than 1 pound. 2). My calculation (as previously modified) added back in the .50
June 5, 200322 yr Hi Lee, There is also an issue as to how the Round would be. 1,55 ---->2 1,45---- >1 Not used with lbs, but I am with Tons in my business, and it is likely that I'd charge a 1.999 Tons to 2.00 Tons instead of 1 Ton. In fact, it is also likely that my transporter would rather round up a 1.450 Tons to 1.500 Tons.
Create an account or sign in to comment