I feel like I must be overlooking something here. I have downloaded the API Level 10
API through the SDK Manager. If I try to create a new project I can't, because only Holo
themes are available, all of which require at least API Level 11
. I have no other theme option, thus the Next button is greyed out. Is there a way to specify a compatible theme?
Asked
Active
Viewed 4,357 times
3

theblang
- 10,215
- 9
- 69
- 120
3 Answers
3
if you does not see the None option go to these files and make sure the template is configured correctly:
{Install_Path}\android-studio\plugins\android\lib\templates\gradle-projects\NewAndroidApplication\template.xml
{Install_Path}\plugins\android\lib\templates\gradle-projects\NewAndroidLibrary\template.xml
{Install_Path}\sdk\tools\templates\projects\NewAndroidApplication\template.xml
{Install_Path}\sdk\tools\templates\projects\NewAndroidLibrary\template.xml
open each file in text editor (Notepad++) and search for 'baseTheme'. there should be a 'parameter'xml element with that id.
Be sure the parameter looks like this
<parameter
id="baseTheme"
name="Base Theme"
type="enum"
default="none"
help="The base user interface theme for the library">
<option id="none" default="true">None</option>
<option id="holo_dark" minBuildApi="11">Holo Dark</option>
<option id="holo_light" minBuildApi="11">Holo Light</option>
<option id="holo_light_darkactionbar" minBuildApi="14">Holo Light with Dark Action Bar</option>
</parameter>
and not like this:
<parameter
id="baseTheme"
name="Base Theme"
type="enum"
default="holo_light_darkactionbar"
help="The base user interface theme for the application">
<option id="holo_dark" minBuildApi="11">Holo Dark</option>
<option id="holo_light" minBuildApi="11">Holo Light</option>
<option id="holo_light_darkactionbar" minBuildApi="14" default="true">Holo Light with Dark Action Bar</option>
</parameter>
especially for the file '\android-studio\plugins\android\lib\templates\gradle-projects\NewAndroidApplication\template.xml'

d.popov
- 4,175
- 1
- 36
- 47
-
Very nice! I replaced the `baseTheme` parameter in the first file that you listed. I was then able to select `None` to get past that screen in the new project wizard. It originally looked like [this](http://pastebin.com/BTf9khWG), which is exactly what you posted. I guess this is a bug? – theblang Nov 07 '13 at 16:33
-
I believe so. I haven't bothered to search though. I had other problems trying to make Android Studio work with API 10. There were a lot of issues at the end, so i compile with API 11 now, and still deploy to Android 2.3.6 :) – d.popov Nov 08 '13 at 21:45
-
what if we didn't go through android studio, I mean what to do if I am using adt – neel Mar 15 '14 at 13:16
-
can't find 'android-studio' folder in install path, though i can find 'sdk' folder, any changes or anything? – Jul 03 '14 at 05:46
-
I do not have the latest version, that probably you are using, so i can not test and confirm the path, but the important thing is to find the file that is holding the definitions. If you can find in the '\NewAndroidApplication\template.xml' file, containing these xml content, then it is fine. It was a bug when i was using AndroidStudio, maybe they also fixed it since then. You can search for "template.xml" files with the appropriate path in the whole instalation dir with Notepad++, and see which file is fixing the problem. it must be somewhere there... – d.popov Jul 04 '14 at 11:36
2
This work for me:
- Go to [SDK_Folder]\tools\templates\activities\BlankActivity...
- Open templaste.xml with Notepad++ (or another txt editor)
- Find the line (minBuildApi=" x ") where "X" is the API you will work.
Best Regards, jfidel87

jfidel87
- 13
- 3
0
The Android Studio has a newer version:0.3.1
Look here: http://tools.android.com/recent
Fixed bug affecting the "New Activity" wizard (issue 61258 and issue 61269)
I think it is a bug and solved in this release.

Timuçin
- 4,653
- 3
- 25
- 34
-
I wonder what I would be missing? I installed `API Level 10` through the SDK manager, which I accessed from Android Studio. – theblang Oct 25 '13 at 19:07
-
I think the ones in "Tools" section can be missing or outdated. First try to install missing ones or update old ones. After this, also update the ADT plugin in Eclipse->Check for updates. – Timuçin Oct 25 '13 at 19:10
-
I am confused, I am not using the ADT plugin? I think I just updated in Android Studio. Still only have the `Halo` themes. – theblang Oct 25 '13 at 21:09
-
this is not the case. the bugs fixed are different (read the issue numbers) – d.popov Nov 04 '13 at 21:39