Browsing all posts in "Date".

The Timer Class

Now we try again to make time in java. The Timer class properties give you access to the timer delays and nature of the event firing loops. The delay property dictates the length between repeated timer events (if repeats is true) and initialDelay determines how long to wait before starting the regular, repeating events. Both [...]

Calendar in java

Okey in this night I’ll share you about how to make calendar with java, here is the code
Calendar program
import java.util.Date;
import java.util.Calendar;
import java.util.GregorianCalendar;
public class Main {
// Jumlah hari di tiap bulan, index 0 = Januari
private static final int[] jml_hari = {
31, 28, 31, 30, 31, 30, 31, 31, 30, [...]