0

I have an error when i use intent to start activity when i choose a tab

intent = new Intent().setClass(this, tab1.class);
mTabHost.addTab(mTabHost.newTabSpec("tab_test1").setIndicator("Search").setContent(intent));

the erroe is

Sorry !
The Application has stopped unexpectedly  , please try again later 
Andreas Dolk
  • 113,398
  • 19
  • 180
  • 268
Adham
  • 63,550
  • 98
  • 229
  • 344
  • Please post up a logcat error output for that exception and also by convention please name all your classes with a capital. – Octavian Helm Nov 15 '10 at 14:53

2 Answers2

1

look here for a possible solution (this seems to be a common TabHost issue)

Community
  • 1
  • 1
KevinDTimm
  • 14,226
  • 3
  • 42
  • 60
0

You've most likely not defined the classes (activities) you are trying to load in your AndroidManifest.xml.

Octavian Helm
  • 39,405
  • 19
  • 98
  • 102