how to solve the problem in android studio is that in the basic (helloword) program i am facing a problem is that in setcontentview line the R.layout in "R" is showing red mark. can you tell me how to solve this problem. Another problem is that my sdk location is not fecthing it is showing that "sdk location should not contain whitespace, as this can cause problem with the NDK tools".
Asked
Active
Viewed 105 times
0
-
1Possible duplicate of ["cannot resolve symbol R" in Android Studio](http://stackoverflow.com/questions/17054000/cannot-resolve-symbol-r-in-android-studio) – Chris Stillwell Oct 28 '16 at 18:39
-
_" it is showing that "sdk location should not contain whitespace"_ Then install the Android SDK in a path that doesn't contain any spaces. – Michael Oct 28 '16 at 21:56
1 Answers
0
The problem: android sdk location should not contain whitespace as this can cause problems with the ndk tools
I have already solved this problem. This is because in your path has white space. For example, I had this path "C:\Program Files(x86)\Android". there is a space in "Program Files(x86)". So, I moved the whole folder of Android to this path with no white space "C:\Android".

Raja
- 1
- 1
- 1
- 2
-
Actually, in many cases Android Studio let you use your SDK from a path with some spaces. At least it works for me. Just click next or whatever button is available there. – Mark Delphi Mar 27 '20 at 18:19
-
I have tried several times until finding this solution. Maybe, the problem is when I had old versions of Android Studio and SDK mangers long time, I updated to the new versions. – Raja Mar 27 '20 at 18:29
-
In fact, I have the latest update. I now check it. The message said "You already have the latest version of Android Studio and plugins installed". – Raja Mar 29 '20 at 06:30