Formula Calculator

Hello,
I’m trying to build an online calculator in one of my RapidWeaver websites.

I need a form that works out the number of days between two dates, and then a calculation to work the sum owed, and then a second calculation working out the number of days between a second two sets of dates to work out a second sum owed, and then those two sums added together.

Is there a Stack that can do that?

I’ve looked at Formula, I’ve looked at CalcStack, I’ve looked at Total Calculator, none of these as far as I can tell will do the above.

Any help would be so much appreciated.

It sounds like something quite specialist that would need to be custom coded exclusively for you.

Certainly not impossible (I get asked to put these sorts of calculators together all the time) but definitely not an “off the shelf” solution ready to go straight in your website.

Does the calculator need to take into account of weekends, public holidays, leap years, things like that?

Are the variables you pass into the calculator fixed or something that changes often?

Have a look at @joeworkman’s Pi stack - https://www.weavers.space/stacks/pi. Not 100% sure it’ll do exactly what you’re after, but another one to investigate (and I’m sure Joe will be along soon to help!).

It’s for a late payment calculator on invoices overdue.

Basically the user input fields would be:

Invoice total
Date invoice became overdue
Today’s date or date to calculate too.

Then behind the scenes, (I already have the formula in an excel spreadsheet I’ve been using for years), I need a formula that works out ‘days between todays date and date invoice came overdue’ so that I can then work out how many days the invoice has been overdue, work that out a decimal point for the year, and then times that fraction by the invoice total and the interest rate of 8%.

In excel, it’s a fairly simple formula. I just want to convert that to a website.

I’m trying to shy away from paying a developer to do it. With these uncertain times, and the base interest rate fluctuating day to day, I’d have to get the script rewritten constantly!

So how are you currently managing that in Excel? Are you already using some sort of macro or API to fetch the daily interest rate from somewhere?

A custom calculator would do the same as Excel - either you change the interest yourself in a stack setting or the developer would add an API so the interest rate is fetched and updated automatically every day. In the same way that currency conversions would be handled.

There are no free calculator stacks available for RW I am aware of. It is something you are going to have to pay for one way or another. Or switch to using another publishing platform like Wix or Wordpress and see what free calculators exist over there, if you don’t have the money to buy something.

Ah no, sorry, I don’t mean for free, I’m happy to buy a stack and implement it myself. I’ve spent a small fortune so far on stacks for RapidWeaver over the last decade!!

As for the interest rate. In my excel spreadsheet, each time it changes, I add another part to the formula.

Without going too indepth, if you were owed £100 by someone, and they owed the money to you on the 1st January, well the interest rate you can charge for the late payment from the 1st January to the 11th March 2020 would have been 8.75%, but then from the 11th March to the 19th March, you would only have been able to charge 8.25% in interest, and then from the 19th March to today’s date, you can only charge 8.1% in interest.

So I have to have a calculator that works out the interest payment on the overdue invoice and make sure the calculations are correct for each period, before adding up the payment at the end and say:

You can charge £12.37 in late payment interest on the overdue invoice, plus the late payment fee of £40.

Hence the need for me to buy a stack that I can do it in myself.

I’m looking at the Weaver Stack Pi, and it ‘looks’ like it may be possible with that stack…

This definitely sounds possible with Pi. It will not automatically bring in any interest rates though. You will have to input that inside of a hidden form field. You could possibly manage that without publishing through Total CMS if you are using that.

Thanks for the response Joe, I bought Pi, and I’m just going through the videos on how to use it. I’m finding it a little too complex at the moment for my knowledge set as I’m not a web developer, I just build my own small company’s website, but I’m sure I’ll get there.

I don’t need CMS on the site, when the interest rate changes yet again, I’ll just log in and update the formula, if I can get it working to how I need it to work. Might take a few days for me to work it out.

Make sure that you look at the demo file. Sometimes looking at a working example makes things clear. There are a number of experienced Pi users on the WS community as well. If you run into any roadblocks don’t be scared to post over there and we can help out.

I would also suggest maybe joining one of Joe’s Friday hangouts. If Paul Russam joins, he is the master with the Pi stack!!

Thanks Robert, I’ll keep a look out on the Friday Hangouts. But I’m also going through Joe’s tutorial videos on the stack as well. I’m pretty certain it’ll do what I need it to do, but I haven’t actually even managed to get the Demo File to work properly on my computer yet, but I’ll get there I’m sure.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.