Current financial year

How to get current financial year, for example 2019-2020 or 2019-20.
is there any command by which we can get the Fy date as above.

For 2019-20 use below code,
Now.AddYears(-1).ToString(“yyyy”)+"-"+Now.AddYears(0).ToString(“yy”)
and for
2019-2020 use,
Now.AddYears(-1).ToString(“yyyy”)+"-"+Now.AddYears(0).ToString(“yyyy”)

1 Like

Hi @Manoj_Gandham1,

I hope below code might help you
Add a if condition
If Now.Month<=3
Then
Now.AddYears(-1).ToString(“yyyy”)+"-"+Now.ToString(“yyyy”)
Else
Now.ToString(“yyyy”)+"-"+Now.AddYears(+1).ToString(“yyyy”)

1 Like

@Manoj_Gandham1 You can even try this
Now.AddYears(-1).Year.tostring+"-"+Now.AddYears(0).Year.tostring

thanks @aanandsanraj it worked for me based on the month.

You’re Welcome @Manoj_Gandham1 :slightly_smiling_face: