0

My application using a tab layout and previously compiled and run fine. But it's raising an exception now. I recreate the emulator and it made no rusalt. The error shown in Eclipse console is as below.

[2013-11-20 11:42:52 - Dex Loader] Unable to execute dex: java.nio.BufferOverflowException. Check the Eclipse log for stack trace.

[2013-11-20 11:42:52 - AndroidTabLayout] Conversion to Dalvik format failed: Unable to execute dex: java.nio.BufferOverflowException. Check the Eclipse log for stack trace.

My code contain a simple tab application.

    TabHost tabHost = getTabHost();

    // Tab for Travaling
    TabSpec Travaling = tabHost.newTabSpec("Travaling");
    Travaling.setIndicator("Travaling", getResources().getDrawable(R.drawable.icon_travaling_tab));
    Intent TravalingIntent = new Intent(this, TravalingActivity.class);
    Travaling.setContent(TravalingIntent);

    // Tab for Maps
    TabSpec Maps = tabHost.newTabSpec("Maps");
    // setting Title and Icon for the Tab
    Maps.setIndicator("Maps", getResources().getDrawable(R.drawable.icon_maps_tab));
    Intent MapsIntent = new Intent(this, MapsActivity.class);
    Maps.setContent(MapsIntent);

    // Tab for Scheduling
    TabSpec Scheduling = tabHost.newTabSpec("Scheduling");
    Scheduling.setIndicator("Scheduling", getResources().getDrawable(R.drawable.icon_schedulingIntent_tab));
    Intent SchedulingIntent = new Intent(this, SchedulingActivity.class);
    Scheduling.setContent(SchedulingIntent);

    // Adding all TabSpec to TabHost
    tabHost.addTab(Travaling); 
    tabHost.addTab(Maps); 
    tabHost.addTab(Scheduling);
}

}

Is this some problem with Android Support Library???

I Googled for an answer, but did't have a working solution. I would appreciate your help in this matter. Thank you!!!!!

Samantha Withanage
  • 3,811
  • 10
  • 30
  • 59

0 Answers0