I am newbie to android. I working on my HELLO WORLD project. Initially I had AVD which looks like
Then something went wrong so I deleted all Android stuff from Eclipse (except my project) then I added all things again to my Ecl开发者_StackOverflow中文版ipse.
So now I have:
1) Android SDK tools , revison 12
2) Android SDK platform-tools,revision 6 3) SDK platform Android 3.2,API 13,revision 1Now I got a new emulator which looks like a tablet emulator .
So my questions are
1) How can I get the previous emulator as Image 1 ( which looks like phone not tablet) ? 2) I am also getting error "Unable to resolve target Android-8". Why it is ? and how to get rid of it ?Answers to your questions:
Ad 1) You need to install SDK platform for Android 1.x/2.x, Android 3.0 is dedicated to tablets so there will be no phone-like emulator,
Ad 2) Android-8 means Android API Level 8, this means Android SDK version 2.2.x. so you will need to install SDK for Android 2.2.x from the Android SDK Manager
More about Android API levels can be found here: http://developer.android.com/guide/appendix/api-levels.html
1.when creating avd you are selecting target.If you select target 2.1,2.2..You will see the first emulator and for the later one your are selecting taget 3.2 . So it looks like this.
2.You are importing/creating project from previous one whose target was api level 8.Now you are trying to run it in avd which is some other.So in manifest file set minSDK as your new avd
With the SDK manager, you have to create a new virtual device. For this virtual device you will set the Android version of your device (must be < 3 to have the "old" look).
It is simple
1) Create AVD
2) While creating if u want to develop for smart phone, select the target version <= 2.3 (Which will get you the keyboard)
3) While creating if u want to develop for tablet, select the target version as >= 3.0, which will get you the big pad emulator with no keypad.
Note: From Icecream sandwidch onwards the version is for both Smart phones and Tablets.
Regards,
SSuman185
You need to create new AVD with the target that you need,or edit the settings of the AVD that you are using now. In Eclipse go to menu : Window -> Android SDK and AVD Manager and you will see a list of your AVD(if you have more than one).And after that you can select the one that you have,and press edit with changing the target to 1.5 and upper version or create a new one pressing button New.
精彩评论