Hi There,
So I am trying to create a due date for invoices based on payment terms that have been agreed with a company.
I managed to do an x amount of days after the invoice date. Problem is I'm trying to do the same thing except it's for x amount of days after then end of the month.
So I first thought I could calculate the difference in days and subtract them from the invoice date and add 1 month to it.
Then I could add x amount of days, except this doesn't work.
Is there a method to either set the day of a date or create a date based on a string given a certain format?
Or is there any other way to calculate this?
Is there also a toString() function to calculate due field that shows the amount of days the invoice hasn't been paid past the due date? If it has been paid within the due date it will display the due date.
Thanks in Advance!