on 01-08-2015 10:47 AM
Hello,
My name is Neuza Sous, and I'm working with Business Object since last months so I need your help so solve a little problem.
I had use the following formula to give me the 'Last day of previous month', but now the formula stop worked because when it calculates the month it takes one the the current month, but in case of January this doesn't work because is the month 1.
I need to current the formula or update it, and I thought to do it we a 'If' but I'm not sure about how to do it.
Can you please help me?
Thank you in advance.
Neuza Sousa
Hi Neuza,
Try the below formula in WebI to get last day of previous month for any month in the year
=FormatDate(RelativeDate(ToDate("01/" + FormatDate(CurrentDate();"MM/yyyy");"dd/MM/yyyy");-1);"dd/MM/yyyy"),
Regards,
Balajee SK
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
A bit long winded,but gives the answer you need. There probably is a better way of doing it.
=ToDate("01/"+(ToNumber(FormatDate(RelativeDate((ToDate("01/"+(ToNumber(FormatDate(CurrentDate();"MM")))+"/"+ToNumber(FormatDate(CurrentDate();"yy"));"dd/MM/yyyy"));-1);"MM")))+"/"+ToNumber(FormatDate(RelativeDate((ToDate("01/"+(ToNumber(FormatDate(CurrentDate();"MM")))+"/"+ToNumber(FormatDate(CurrentDate();"yy"));"dd/MM/yyyy"));-1);"yy"));"dd/MM/yyyy")
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Can you add a condition (textual explanation), if(month=jan, 1st day of lastyear december,this formula). ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.