Skip to content Skip to sidebar Skip to footer

A Method To Store Date And Time In Android Using Firebase?

I'm new to Android Studio and new to the Firebase database as well. I have created an app but I don't know how to store date and time. Can you help me guys? Here below is my code:

Solution 1:

Calendar c = Calendar.getInstance();
            c.set(Syear, Smonth, Sday, Shours, Sminute);
            long startDate = c.getTimeInMillis();

where Syear, Smonth, Sday, Shours, Sminute you can get it from your OnDateSet and OnTimeSet now you can put Datetime to your FireBase as long


Post a Comment for "A Method To Store Date And Time In Android Using Firebase?"