0

I got the following error after updating my android sdk revision to r12.

error: Error retrieving parent for item: No resource found that matches the given name '@android:style/AlertDialog'.

Here is my xml file.

<?xml version="1.0" encoding="utf-8"?>
<resources>
    <style name="CustomDialogTheme" parent="@android:style/AlertDialog">
        <item name="android:windowFrame">@null</item>
        <item name="android:windowContentOverlay">@null</item>
        <item name="android:backgroundDimEnabled">true</item>
        <item name="android:windowIsTranslucent">true</item>
        <item name="android:windowNoTitle">true</item>
        <item name="android:windowAnimationStyle">@android:style/Theme.Dialog</item>
    </style>
</resources>

I didn't change anything in the code and the only thing that I did was upgraded the Android SDK.

Chirag
  • 55,270
  • 29
  • 150
  • 194

2 Answers2

0

android:style/AlertDialog is not a public style and you should not use it. Please refer to this thread How to change theme for AlertDialog

Community
  • 1
  • 1
denis.solonenko
  • 11,179
  • 2
  • 26
  • 22
0

Finaly i found the answer . i know its not the proper way but it works for now.

I managed to fix it by replacing the platform-tools_r06 with platform-
tools_r05 in android sdk folder

you can dowload platform-tools-r05 from here.

Chirag
  • 55,270
  • 29
  • 150
  • 194