Run Butterknife samples on Android Studio - android-studio

I try to run Butterknife project samples on Android studio 1.2 and keep getting that issue :
"Error:Android Source Generator: [butterknife-sample] AndroidManifest.xml file not found"
If I try to run the SimpleActivity, same issue : AndroidManifest.xml doesn't exist or has incorrect root tag.
Any idea

Related

Can't find "Sync project with Gradle files" in Android Studio running on Mac

I'm running into the error when I tried to run the existing project.
Error: "AndroidManifest.xml doesn't exist or has incorrect root tag"
I'm seeing a lot of solutions suggesting using "Sync project with Gradle files". I'm running Android Studio on my Mac and did not see that option. I do have AndroidManifest.xml file in the project but for some reason Android Studio can't find it.
I have the file under project_name > app > src > main > res.
I have Android Studio 4.1.1 and macOS Catalina 10.15.7
I also got a recommendation when I open up the Android Studio
Migrate Project to Gradle?
This project does not use the Gradle build system. We recommend that you migrate to using the Gradle build system.
More Information about migrating to Gradle
Don't show this message again.
Not sure what to do about it. I'm pretty new to Android Studio. Thanks!

How to solve gradle; "contains too many directories after formatting system"

I am developing an app using android studio and java. I downloaded gradle 6.1.1.zip and it was working fine. I formatted my system and installed android studio. I want to use the same gradle but I'm getting error.
file:/C:/sam/gradle-6.1.1-all.zip' contains too many directories. Expected to
find exactly 1 directory.
The zip file contains only one gradle. How do I solve this issue?
According to this android dev doc, you can specify the gradle version either in: File > Project Structure > Project menu in Android Studio, or in the file gradle/wrapper/gradle-wrapper.properties . In your case, for gradle 6.1.1.zip, you use the following in the above mentioned file:
...
distributionUrl = https\://services.gradle.org/distributions/gradle-6.1.1-all.zip
...

Getting Error in style.xml file in android studio.Can not resolve symbol theme.Validates resource references inside Android XML files

The Application build and run correctly and there is no error in gradle build but the style.xml shows error.
I am using android studio 3.1 gradle version 4.4
Please see The Image.
from the top menu File -> Close project.
Remove it from the projects list.
Open existing project -> choose the project folder.

Getting error while importing my old project to Android studio 2.0

I just download the latest Android studio and trying to import my old project which was good with the last version. But I am getting
Error:org.gradle.tooling.BuildActionExecuter.withCancellationToken(Lorg/gradle/tooling/CancellationToken;)Lorg/gradle/tooling/BuildActionExecuter;
I am also getting this error when I am creating new projects.
Any suggestion to solve this problem?
Method : 1.
1.Close Android Studio
2.go to android-studio/plugins/gradle/lib
3.Delete (or better move them somewhere to have a backup) all
gradle-*-1.8 files
Start Android Studio again and rebuild/refresh.
It should work
Method : 2.
Choose another path of gradle in:
File --> settings --> Build,Execution --> Build Tools --> Gradle
If you use of ver 2 select path of installed android studio and select gradle Folder.
I just deleted all the file from my install directory and re-extracted the file, the problem gone.

Android Studio 1.1.0 "Cannot resolve symbol" error on #string values in manifest

Having just renamed the directory in which my Android Studio project sits, AS is now confused about the values pulled from the res/values/strings.xml file into the manifest. They all have red errors on them: "Cannot resolve symbol...". The values definitely exist.
I've tried File -> Invalidate Caches / Restart... No help. I've tried Clean Project. No help.
The run configuration for the app also has a red cross on it and says "Error: AndroidManifest.xml doesn't exist or has incorrect root tag."
Upgrading to Android Studio 1.2 has fixed this.

Resources