Java tutorial
//package com.java2s; import java.text.SimpleDateFormat; import java.util.Date; public class Main { private static SimpleDateFormat serverSideDateFormator = null; public static long convertInMillisecond(String dateStrServer) { //String orderDate = null; try { Date date = serverSideDateFormator.parse(dateStrServer); return date.getTime(); } catch (Exception e) { e.printStackTrace(); } return 0; } }