I have an App that depends on this other module. "Make project" works, but trying to run it results in this error:
Similar answers point to the gradle files, so here is a ss of them:
I have no idea what is going on. I followed very simple steps on how to create a java library for my android project from this question: How to create a library project in Android Studio and an application project that uses the library project and haven't been able to find my mistake so far.
Related
I am having trouble with Android Studio. I forked the project here:
https://www.google.com/url?q=https://github.com/ubclaunchpad/Android-Calculator&sa=D&ust=1514703967854000&usg=AFQjCNHLwSAZ_JER6VlZ8LP6AtTzfUVBog
and cloned it in Android Studio, but it keeps telling me that I should Migrate to Gradle. However, if you look at the project files on github, there are a lot of gradle related files, so clearly the project does use gradle. How do I fix this? Is there a simple solution?
it works fine with me ensure that you open Calculator folder as a project, not Android-Calculator-master
check this photo
open calculator folder
I'm building my first Android app and I found a java project on github that I would like to integrate with my app. Is it possible for me to manually add the java files to my android project directory at
app -> java -> com.example.appname
The src -> main directory of the java client has a nested file structure so I'm not sure if this would cause issues.
I already tried the solution from this post but I didn't see the option presented in step 2
How to import existing java project into android studio?
Please use java code in MainActivity.java or other Activity. It Will work.same code you applied on java will also work on Activity .java
You can add java project as module to your android project.
Check Method 2 in this link
I'm trying to build simple Qt project with android profile, but receiving strange error:
Android_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/src/org/qtproject/qt5/android/bindings/QtApplication.java:46:
error: duplicate class:
org.qtproject.qt5.android.bindings.QtApplication public class
QtApplication extends Application
after androiddeployqt run
Right, I'm going to assume this is the same as what has happened to myself:
You've upgraded Android Studio which has broken the Qt build for Android.
You've managed to solve the issue of upgrading gradle, resolving previous errors. ie from here
Now you're getting 'error: duplicate class'.
Solution:
When Qt builds the project all files are stored in 'build-myappname-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug
Delete that folder and rebuild the project.
You may need to clean and rerun qmake, but I doubt that is required. I only do that out of habit.
Coming from someone who's only worked in Java casually / when situations absolutely called for it - I'm having a hard time trying to set this up.
I'm trying to follow along this tutorial to build a native Android plugin usable from Unity:
http://jeanmeyblum.weebly.com/scripts--tutorials/communication-between-an-android-app-and-unity
But unfortunately the author skips over the basic steps (understandable for those with prior android dev experience... but not for me!)
I've gone through a checklist of what I had to install, and so far I have:
Android SDK / Android Studio.
Java SDK / SRE 1.8.
Apache ANT.
Made sure I added all the paths required in my PATH System Environment variable to execute:
android
ant
and... java
But at this point, I have no idea what type of Android project I'm supposed to create (see image).
Other puzzling questions: Which SDK do I choose, do I just leave that to default? How do I indicate that this is only a Service JAR, and not an Activity? (assuming that's what's required to be usable in Unity3D).
And after the project is created, can I just open one of the existing classes to write my Service inside it? Or do I need to create a new class file and extend from Service / IntentService?
I can probably figure out the rest to implement in Unity3D after I can manage to compile the JAR file. It's just that initial step I have no idea how to setup.
You will choose very first one "Add No Activity"
The tutorial you are following might be outdated. Here is a good one : http://eppz.eu/blog/unity-android-plugin-tutorial-1/
I just download the sample file in Android Developers site (https://developer.android.com/training/multiscreen/index.html), then open this using Android Studio.
But I found the run button is disable and I can't find any way to execute this (just like this http://chuantu.biz/t5/34/1474269694x3394677986.jpg).
Any one can tall me how to run this file in Android Developers?
Try to set "app" or similar on here:
UPDATE1 (Maybe it's the problem)
That project it's not a new gradle project then maybe you imported wrong, you must import the project as "Import project (Eclipse ADT, Gradle...)"