So you wonder why in your Android emulator, the Date is either behind or ahead once you set it with an epoch time.

Now, here is the thing. While the emulator’s Timezone setting is set to automatically sync, it won’t when in the Android emulator.

You will have to uncheck the setting and select a Timezone manually.

  • Go to Settings > Date and Time
  • Uncheck Automatic time zone
  • Select your desired time zone

That should do it. Your epoch converted Date object will then display the correct date.

Well, there is no direct way to get the offset of a timezone such as -08:00 from the DateTime object. The only solution that I found working was to format it by using the DateTimeFormat class.

Here is how to do it:

This is a fairly common problem that newbies using Google Web Kit within Eclipse encounter with their the Java Runtime Environment. Chances are you just upgraded your JRE to 1.6.0_31.

The solution is to add an extra parameter in your virtual machine run configuration using either:


If that does not work, try this.


To go to the run configuration, do the following:

  1. Right click project name
  2. Go to Run As > Run Configurations
  3. Go to Arguments tab
  4. Under VM Arguments, add the extra parameter, then click Run button

There you go! That should get you back into development mode!

Related Posts Plugin for WordPress, Blogger...