Questions tagged [android-studio]

15725 questions
1

votes
3

answer
5.5k

Views

Android Studio TFS (team foundation server)

We use TFS 2012 in our company for version controling. According to this discussion: https://groups.google.com/forum/#!topic/adt-dev/C_Gc6hVkig0 TFS plugin should come for the version 1.0, that is already released. Any news? UPDATE Now we have TFS 2013 and use git. Everything works fine. For anyone...
android_dev
1

votes
2

answer
667

Views

Do I Have to Replace Android LocationClient with GoogleApiClient?

I made the bad move of updating my Android SDKs and now my app is all jammed up. Android Studio is not showing me any errors in my code, but when I compile I get several build errors that say "cannot find symbol class LocationClient" I've read several threads about this and they seem to point to the...
Chris
1

votes
3

answer
3.7k

Views

Zxing QR Scanner Embeded disable beep sound

I have integrated Zxing QR Scanner in my Android app using the instructions here: https://github.com/journeyapps/zxing-android-embedded ( Adding aar dependency with Gradle) Everything works great with the scanner but when the scan is succesfull and the phone media volume is not on mute the app gener...
Victor Pavel
1

votes
1

answer
3.7k

Views

I'm having issues importing ViewPager with Android Studio?

I'm trying to import a project into Android Studio. I'm getting weird errors. Information:java: Errors occurred while compiling module 'library' Information:Compilation completed with 100 errors and 5 warnings in 26 sec Error:(31, 31) java: package android.support.v4.view does not exist /Users/clxx...
losethequit
1

votes
2

answer
2.3k

Views

Android Studio - Error Building - Android tasks have already been created

Getting the following error when building the project: Error:(2, 0) Android tasks have already been created. This happens when calling android.applicationVariants, android.libraryVariants or android.testVariants. Once these methods are called, it is not possible to continue configuring the model. Ro...
Rendy Del Rosario
1

votes
1

answer
981

Views

Android Hello World My First App has got big size [duplicate]

This question already has an answer here: Reduce Android Application Size 3 answers I have created my first Android Hello World App from this tutorial http://developer.android.com/training/basics/firstapp/index.html. I did everything exactly as described in the lesson. Then I run this App on my tab...
Dumas45
0

votes
0

answer
7

Views

Redirect from a web view to a new activity android app

In this application im trying to have a landing pagage "Main activity 1" to display a login/registration website. Then only afther the user have succesfuly logged in i want to display the second activity . I know that i can use parse to create an SQL DB but in this case i want to avoid that and use...
Space Core
1

votes
3

answer
1.9k

Views

cannot find symbol variable ic_launcher

I am trying to build an empty default project in Android Studio for Android Wear. I get this error: Error:(23, 41) error: cannot find symbol variable ic_launcher Error:Execution failed for task ':wear:compileDebugJava'. > Compilation failed; see the compiler error output for details. I am a total ne...
Mona Jalal
1

votes
1

answer
112

Views

Two different android studio but same project, are they generated differently?

My laptop has dual boot Ubuntu/Windows and my project is in github. Usually I used to code in ubuntu's android studio. But yesterday I pulled my project to windows android studio from github and when I compiled the project while installing on a device it said Failure [INSTALL_PARSE_FAILED_INCONSISTE...
Aawaz Gyawali
1

votes
1

answer
3.1k

Views

can not resolve 'com.facebook.fresco:fresco:0.7.0+'

I want to import Fresco library into my project ,so I add the following line to the dependencies section of my build.gradle file: compile 'com.facebook.fresco:fresco:0.7.0+' and then I build the project , but It failed with "Could not resolve com.facebook.fresco:fresco:0.7.0+.": My development envir...
MummyDing
0

votes
0

answer
17

Views

How to add two elements in single list view row without using custom adapter?

I am working on a project , where i don't have much time to create a custom adapter's for my list view . Can anyone here help me, how to add two elements values in a single row , without custom adapter Earlier Reply is appreciable .
NICK
0

votes
0

answer
16

Views

AndroidManifest icons doesn't seem by Debug

I have been working on the project so far but I got a weird problem.I ran two days ago my project there is no problem like that but today I got instant-run/AndroidManifest.I have checked all file direction of folders no error in the path. All folders are still there. The errors were shown in below...
Zekeriya Yoldaş
0

votes
0

answer
4

Views

using Jenetics library in android studio

Please I want to know how to use the Jenetics Genetic Algorithm library in android studio. I am working on an interior design app using sceneform and a genetic algorithm.
Jonathan Ato Markin
1

votes
2

answer
2.4k

Views

How to change default template layout files in Android Studio

As you know every time you create new project with some activity, Android Studio generates a default activity_main.xml file with RelativeLayout as the root element and one TextView. But I prefer to use LinearLayout without any nested views. How can I change the way Android Studio generates the defau...
Arthur
1

votes
2

answer
2.1k

Views

Android studio Load Image url into listview

I want to fill a listview with text and images. I receive this information by my mysql database, in JSON format. I have a field called "FOTO" and I store into this the path to the photo like: "http://....../1.png". I get and android.os.NetworkOnMainThreadException using this code, but I don't know h...
img.simone
6

votes
4

answer
98

Views

Which way is correct when I integrate GitHub to my Android Studio 3.3.1 project?

I hope to use GitHub in my Android Studio 3.3.1 project. I google some ways, I find the ways divide into two way. Way 1: Such as https://medium.com/code-yoga/how-to-link-android-studio-with-github-312037a13b99 It need VCS > Import into Version Control > Share project on Github Way2 : Such as htt...
HelloCW
1

votes
2

answer
1.3k

Views

Android Toast.makeText(this, …) not working for AppCompatActivity

Using Android Studio, I'm trying to call Toast.makeText() method inside a class that extends AppCompatActivity by passing this as the first argument (which should be a Context) as shown below: Toast.makeText(this, messageResId, Toast.LENGTH_SHORT).show(); This is giving me the following error: Canno...
OMGitzMidgar
1

votes
2

answer
169

Views

How to tell android studio the location of a pre-existing NDK?

Im trying to use my pre-existing NDK with Android Studio , it offers an option of downloading a new NDK and auto setup , but i want to use the version i was using before i downloaded Android Studio , how to tell it the location of the NDK i already have ? Do i have to set the NDK_HOME environment va...
Dhia Hassen
0

votes
0

answer
3

Views

How to launch my RPG MAKER MV game in my android studio application

I imported my game created using "RPG MAKER MV" and I therefore have a folder "www" in my assets. I wish I could activate (launch) my game by clicking on a button created in my basic application. It would be a kind of nested game. I do not really know how to do it so I did not try on my own. I tried...
Adrien Moinnet
1

votes
1

answer
145

Views

Change Git Roots in Android Studio

I have a Android git project with multiple git submodules. For some reason, the Android Studio git integration selected the root to be one of the submodules, so I can't see my changes in the "Version Control" pane. Any idea how to modify the git roots of a project? I saw this: https://www.jetbrains...
ElyashivLavi
1

votes
1

answer
43

Views

JavaDoc @link package in Android Studio

I need to link to a package in JavaDoc. Example: @param example description (see {@link com.example.packagename this}) With the code above, I get this message: warning - Tag @link: reference not found: com.example.packagename Linking to a class in the same package works fine, but I need to link di...
John_Dark
0

votes
0

answer
14

Views

How can I get file (.png or .jpg) capture image from camera and send it to the server?

How can I get file (.png or .jpg) capture image from camera and send it to the server ? From the server I can download that images
ivan saron
0

votes
0

answer
7

Views

How can i fix my firebase auth connect error?

as I think, my activity has no problem. but I think this error from cannot connect with firebase consol well. even I had been connecting with firebase consol immediately. sorry, I try to solve with closed questions, but I couldn't solve this error by my self. I'm sorry to say this, what is 'E/memtr...
Benedict Arthur
1

votes
2

answer
34

Views

How to Display a variable from Mainactivity in a second Activity's Texview

Im a little stuck, how can i get a variable from main activity to be displayed on a second activity? a code example would be great. Also a second Problem: How can i create a function in mainactivty when a button is pressed in a second activity? This is what i have so far, but when i press the butto...
Camden
1

votes
1

answer
27

Views

Android App is not running. Emulator says it keeps shutting down

I have some code that should be very simple to run on an Android App. I have a textView that I am trying to print the day of the year out of 365 of 366. However, even though the code is simple, it is not running but there is also no error message. @Override protected void onCreate(Bundle savedInstan...
Joey Zhao
1

votes
2

answer
73

Views

What does this syntax mean in Kotlin?

I'm new to Kotlin, i don't understand this syntax of code. is it an array or a function call? val editText = findViewById(R.id.editText) The same is JAVA: EditText editText = (EditText) findViewById(R.id.editText);
elkebirmed
0

votes
2

answer
14

Views

How to intregrate python with java Android studio?

Let's say I have already done algorithms written in python, and now I want to use these algorithms in my android code. Can I use Java to get output from python? I need to send values from EditText as a parameter to python to be calculated in the algorithm and get a result. I can use Android Studio o...
Just Ahead
0

votes
2

answer
15

Views

Empty editText causing app to crash when trying to calculate

I have an app with 4 EditText and one button that is supposed to calculate the inputs given When one of those are left empty then the app crashes How can I validate to throw an error when a EditText is left empty
1

votes
1

answer
13

Views

E/memtrack: Couldn't load memtrack Android studio

I have an issue with lower api I tasted my app on 15, 19 and 22 api the crashes on start the only ones works are 24 and above api I don't know why my app is just Math calculations .I searched a lot to find answer for last 2 days and I tried myriad of thing none of them work for me. Here is my full l...
Ajed
0

votes
0

answer
8

Views

How to display style inheritance information in Android Studio?

Earlier this evening I found that if I pressed control and moved the cursor over a style, for example over the ActionBar in then a new window opened on the RHS of the screen showing the inheritance structure of the style (ThemeOverlay.AppCompat.Dark.ActionBar) and attributes modified with colors dis...
Ewan
0

votes
2

answer
13

Views

How can I update a var inside a whole kotlin class through a method and then retrieve it updated with another method call

I've written a kotlin class with an overridden fun and a fun to update a var into the class scope (I'm tragically new to Kotlin!) class mySampleClass: sampleReference(){ var varToBeUpdated:String = "my string" //var in class scope to be updated fun updateMyVar(gotString:String){ //I tried this, it d...
Michele Rava
0

votes
0

answer
6

Views

Clear selected item on multiple radio group with onCheckedChangeListener

I'm currently working on my college project. In the app I have an activity with a fragment. The fragment contains a layout which has nested linearlayouts with multiple customized radio buttons in it. I can't put one single radio group to enable the single selection for the buttons because of the lin...
Qwerty08
0

votes
0

answer
9

Views

Problems when sending a webcam stream from a laptop to view on a mobile

So basically I am trying to view a stream of my laptop webcam to view it on my android mobile. Here is what I am doing: Laptop: Basic c# windowsform that takes the stream and sends each frame to a server. convert each image to Byte64. Server: A simple Node.js which utilizes Socket.IO to allow commun...
Forenkazan
0

votes
1

answer
24

Views

What libraries are included in the Android SDK?

When you google what the Android SDK is, it says one of the thing's the SDK contains are required libraries. What are these required libraries? Can you name a few? Are they all of the libraries I can find on the Android Documentation website?(AndroidX, Android support library, Android Platform, etc)...
browndoor
0

votes
1

answer
13

Views

How to make part of String text Clickable

How can I display dialog box when part of a String.xml text is clicked. I have a long string and I want to make part of the string to display a dialog box when it is clicked. Now, I don't want the text to take me to a link; but it should appear like a link. Then, it should take me to a dialog box ac...
1

votes
0

answer
7

Views

Set height of the view programaticaly

I need to set height of the view based on screen height. How to do that. Currently the height is set to 50dp. I need to set height of the view as follows View Height Screen Size 32 dp ≤ 400 dp 50 dp > 400 dp and ≤ 720 dp 90 dp > 720 dp Please help me to set the...
Nik
0

votes
0

answer
5

Views

Android Resources linking failed after adding the implementation line in to build.gradle

I am kinda new to this Android Studio development. I am now facing a problem that implementing a payment gateway for my application. I am using Stripe as my payment gateway but I can't add the Stripe Library into the dependencies. This is how my build.gradle file look like. apply plugin: 'com.andro...
Hong Yee
0

votes
0

answer
20

Views

(WebView) view.setOnTouchListener not triggered

I am having the html file in my asset folder. Now i am trying to access the content with onTouch event. The following is my code.I have added two images for the reference. view = (WebView) findViewById(R.id.webview); view.getSettings().setJavaScriptEnabled(true); view.setOnTouchListener(new View.OnT...
Gayu R
1

votes
2

answer
2k

Views

How to upload a WAV file using URLConnection

Curretly, I can upload .wav files by using this command in Terminal (MAC): curl -H 'X-Arg: AccessKey=3f55abc5-2830-027ce-e328-4e74df5a3f8f' --data-binary @audio.wav -H 'Content-Type: audio/wav' http://generic-15327.2-3-11.com/bbb.aaa.eval/abc I want to do the same from Android. So far I have impleme...
Josh
1

votes
2

answer
1.6k

Views

Android Studio error running app: Unable to obtain debug bridge

My antivirus seems to have deleted or removed my adb.exe file from my SDK folder. Permission errors is preventing me to update my platform tools or installing the SDK platform tools. "Stopping ADB server failed (code -1)" "unzip failed \adb.exe. (access is denied)". I have tried restarting my Andro...
Craig Gallagher

View additional questions