I recently installed android studio but can't see the preview of the app.
Asked
Active
Viewed 3,450 times
0

Zoe
- 27,060
- 21
- 118
- 148

Rizwan Rajput
- 1
- 1
- 2
-
Possible duplicate of [Where is Android Studio layout preview?](http://stackoverflow.com/questions/16660039/where-is-android-studio-layout-preview) – Dusan Jovanov Apr 18 '17 at 14:53
-
Your Gradle project sync failed. And there is a `NullPointerException`... Fix those first – OneCricketeer Apr 18 '17 at 17:23
3 Answers
1
When you switch in the Layout.xml
, on the bottom you will see two options: -Design -Text. Chose Text
and then on the top right you will see Preview
appears and so you can click Preview
.

Johny
- 625
- 2
- 6
- 26
-
the preview buttons is shown there but when I open that there is nothing. Just a plus sign there – Rizwan Rajput Apr 18 '17 at 15:06
1
Go to Res->values->styles and change the name of your theme to base.theme. ex-> Theme.AppCompat.Light.DarkActionBar to Base.Theme.AppCompat.Light.DarkActionBar

developer
- 81
- 8
0
Please notice the value on the right of the small android icon, just above where the "preview" should be. There you should pick the API in wish the representation is made. If theres nothing to select there, you will need to install the necessary API packages.

FabioLaranjeira
- 29
- 9