Thanks for your reply simon,
but i am not very clear can you please explain me little bit how can i exactly get GMT time of my local time in milliseconds.
The main problem is i converted the GMT into milliseconds as below:
Date _date = new Date();
long currentTime = _date.getTime();
TimeZone _timeZone = TimeZone.getDefault();
Calendar _calendar = Calendar.getInstance();
int gmtOffset = _timeZone.getOffset(1, _calendar.get(Calendar.YEAR), _calendar.get(Calendar.MONTH), _calendar.get(Calendar.DATE), _calendar.get(Calendar.DAY_OF_WEEK), _calendar.get(Calendar.MILLISECOND));
System.out.println("GMT Time as Long: " + currentTime - gmtOffset);
it gives the correct GMT millis i guess so, but when is send it to the server and compares the server's time in millis(which is converted into GMT) the difference is very large (while it should not be greater than a 10000 millis), so i am really confused whether the conversion is wrong or there is some other problem.
Plz do share if u have any ideas.
Thanks once again.