In this tutorial you will learn how to create a datepicker dialog and print the yesterday's date not just by decrementing the day by 1 which will show 0 if you are decrementing the 1st day.

Download Datedialog.java

Download MainActivity.java

Thank you.

Have a nice day.