Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unknown attribute android

Tags:

android

enter image description here

Getting Unknown attribute error on all android tag.

In layout XML, Auto suggestion is not showing all attributes (like layout_width, layout_height, orientation, orientation & all others android attributes.)

Things i have done to resolve this issue.

Clean Build & Rebuild Deleted .idea file Invalidated Caches/ Restart.. option Turn On Power Save Mode. SDk is up to date.

Unknown attribute android:orientation less. (Ctrl+F1) This inspection highlights unknown XML attributes in Android resource files and AndroidManifest.xml

currently using :

 Android studio 3.2.1
 targetSdkVersion 27
 ext.kotlin_version = '1.2.61'
 build:gradle:3.2.1

I tried with deleting .idea in the path and invalidate cache and restart ,synching the gradle

like image 865
Santhosh Avatar asked Oct 17 '18 11:10

Santhosh


2 Answers

got the same issue recently with Windows7 and Android studio 3.2.1. what's actually helped is clean up of the following folders:

c:\Users\<user>\.gradle\caches\
c:\Users\<user>\.AndroidStudio3.2\system\caches\
like image 120
alexuz Avatar answered Nov 19 '22 02:11

alexuz


100% Working

These two steps will solve.

Do this two steps: 1.Go to folder where you android studio caches are located. I have android studio 3.6.3 For me it's "C:\Users\Lenovo.AndroidStudio3.6\system\caches" 2.Go to the folder where you android studio projects are located. Open the project >then .idea folder and delete the caches. For me its "C:\Users\Lenovo\AndroidStudioProjects\MyDictionary.idea\caches"

like image 34
Nehemiah Narzary Avatar answered Nov 19 '22 00:11

Nehemiah Narzary