i have define code File selectedFile = new File(selectedFilePath); when run and test is it file or not if (!selectedFile.isFile()){ runOnUiThread(new Runnable() { @Override public void run() { tvFileName.setText("Source File Doesn't Exist: " + selectedFilePath); } }); return 0; it give message source file does't exist; why give this message, i have allready convert full code public int uploadFile(final String selectedFilePath) { int serverResponseCode = 0; String file_name = selectedFilePath; HttpURLConnection connection; DataOutputStream dataOutputStream; String lineEnd = "\r\n"; String twoHyphens = "--"; String boundary = "*****"; int bytesRead,bytesAvailable,bufferSize; byte[] buffer; int maxBufferSize = 1 * 1024 * 1024; File selectedFile …

Member Avatar
Member Avatar
+0 forum 1

I have two classes Class1=Manage and Class2=Scan. I want to get the list from manage and check it with a method in Scan. Here is the code. The result that i get is "no" and with debugging i saw that list is empty but i don't know why. Manage.class private ArrayList<String> soy2= new ArrayList<String>(); .... public void onCheckedChanged(CompoundButton compoundButton, boolean b) { //12-1-2019 if (soy.isChecked()) { soy1="yes"; //checked(); soy2.add("Soy"); soy2.add("Σόγια"); soy2.add("soja"); soy2.add("Soybeans"); soy2.add("soybeans"); soy2.add("en:soybeans"); System.out.println(soy2); // //textView.setText("Soy"); // textView.setText("Soy"); // System.out.println(soy2); // System.out.println(checkedAllergens); // } else { soy1="no"; //soy2.remove("Soy"); soy2.remove("Soy"); soy2.remove("Σόγια"); soy2.remove("soja"); soy2.remove("Soybeans"); soy2.remove("soybeans"); soy2.remove("en:soybeans"); System.out.println(soy2); } } //set value …

Member Avatar
Member Avatar
+0 forum 2

Okay so I have been downloading gifs and sending them in the messenger to my friends for years now. But a few weeks ago, something changed. Whenever I download it and send it, the gif is supper choppy with maybe 2 frames per second and the colors are compressed as hell. Please fix this. I don’t understand why something constantly gets broken with this app. Another thing. Embedded youtube links cannot be played. They start and stop after a split second. They have no issue loading, the quality is good, there is sound, but after I press play they stop …

Member Avatar
Member Avatar
+0 forum 2

I'm using android studio to create a multiple choice question app, and i've coded the quiz but so far it just goes on forever. I want to make it so that once the user has answered 20 questions, whether they are right or wrong, the game ends and sends them to an endscreen that I have created, but so far I can't figure out what to do to make this happen. this is what i've tried, it doesn't crash the program but it also doesn't actually do anything. private int round = 0; round = round + 1; if (round …

Member Avatar
Member Avatar
+0 forum 9

Just a quick question, I'm trying to speed up my app and I've seen forum posts where people say reducing the size of pictures speeds up their app. I was hoping to replace my exit cross in the top corner of my app (which is a png because I drew it in a different software) with a shape that I would draw in android studio using xml (draw shape). So would it be better to keep the png or use xml to draw the shape. And if the xml would be better, does anyone know where I could find a …

Member Avatar
Member Avatar
+0 forum 3

I am making an e-commerce android app for a client using firebase. I need to integrate paypal so that the payment deducts from the customer's paypal and received to merchant's(i-e my client) paypal account. For paypal integration i saw tutorials and made two sandbox accounts on my clients paypal. I tested the app and payment is deducted from sandbox(buyer account) of my client successfully. But now i am confused about one thing: As this will be a e-commerce app , the customer will be random anywhere in the world and he will pay an amount from his paypal account, which …

Member Avatar
Member Avatar
+0 forum 1

I want to pass a value (0 or 1) to another page so i can make an ng if to return a different button. Any help? do i need to pass a parameter from .ts file? first page.html <button ion-tem (click)="goUsers()" *ngIf="editors.length == 0" value="0"> <ion-label> Add editors </ion-label> </button> <button ion-tem (click)="goUsers()" *ngIf="editors.length > 0" value="1"> <ion-label> Add more editors </ion-label> </button> second page.html <button ion-button item-end clear *ngIf="value === '0'"> (click)="addEditor(item)"> Add as Editor </button> <button ion-button item-end clear *ngIf="value ==='1'"> (click)="deleteEditor(item)"> Already an Editor </button>

Member Avatar
Member Avatar
+0 forum 3

Hey I want to Develop A mobile app in android for my food business. Can anyone suggest me any company and the cost of the App? Thanks

Member Avatar
Member Avatar
+0 forum 1

Hi guys. I'm about to embark a new journey of learning how to create a android game. So, I don't have to publish it yet. I want to do self-learning. I also want to learn animation along the way. Maybe 2d if 3d is too time-consuming? I've read animation takes a lot of patience and practice which is ok but if you guys think 3d would take too much time, I'd rather try 2d first. Can anyone recommend a free game development platform for Android that is very good for beginners? Preferably, something I can learn animation with as well …

Member Avatar
Member Avatar
+0 forum 2

Hi, i'm using ***lenovo b570e Intel Core i3 (2nd Gen) 2330M / 2.2 GHz and 4GB ram***. But i can't run android studio on it as it is not only slow but its too slow. Currently i don't have budget to buy higher specs laptop i just want to ask 2 things which will be better for me? 1: Shall i Upgrade to 8GB ram (as max memory supported it is 8GB) 2: Shall i use 4GB ram and use real android device instead of emulator? If i choose option 1 then please tell me which ram should i add …

Member Avatar
Member Avatar
+0 forum 1

It may seem impossible on the first sight... But now, I have found a solution. It turnes out to be possibble to emulate the Windows environment and run it side-by-side with Android. As the article about playing PC games on Android (https://eltechs.com/pc-games-for-android-guide/) says this works like that because a special porting technology is utilized. It creates the Windows environment inside Android and then makes a PC game functioning inside this made-up environment natively and independently. Well. let's see! I am going to give it a try and report on the result a little bit later in thist thread!

Member Avatar
+0 forum 0

Hello everyone, I bought one tutorial to learn how to design Android App which used to install Android Studio to work on. However am getting continuous Gradle Sync error in it due to which I couldn't go ahead. Tried all the ways to sort it out given on the internet but couldn't solved the problem. Is there any one who can help me out in this regards Regards Chandan Pathak

Member Avatar
Member Avatar
+0 forum 1

I have a code that picks contacts, the problem is that if a user pick a contact or choose a contact that was not saved on a phone but was saved on google contacts (This is a way many people now save their contacts so that should their phones are lost but contacts are ever lost because when s/he gets a new phone, s/he will just sign in with google account and get his/her contacts) now my app is able to get the name and return it to an EditText but the number/phone number is not returned in these contacts. …

Member Avatar
Member Avatar
+0 forum 6

Hello! I have a grid view with the row model having a image view and text view in it. I set a custom adapter to populate the the grid view with images and texts successfully. But now I want to use a search view to filter the grid view on the base of text in text views. For this I implemented Filterable interface . When i enter the string in my search view nothing happens. I am pasting my code also. Please check it . All the code is in one class. Please view the code in the inner classes …

Member Avatar
+0 forum 0

Hello! I have installed android studio 3.0.1 in my laptop . I had some android projects in my desktop computer (with older version of android studio) But after installing latest version(3.0.1) of android studio in my laptop, i copied projects from my desktop to my laptop and opened that projects in my new android studio(3.0.1) But there appears an error: "Gradle project sync failed. Basic functionality(e.g editing, debeugging ) will not work properly" And in the console a message appears: ""Unable to resolve dependency for: 'app @UnitTest/compileClassPath: could not found any version that matches com.android.support: support-v4:27.+. I can't understand this …

Member Avatar
+0 forum 0

Hi Guys, Am trying to develop an android application with 13 fragments. The app works very well with the navigation drawer, but when I tried to add the code for the function to swipe the screen to switch betwenn fragments, the app stopped to work. I am very new to android development, the reason why I am failing to get to the root of the matter. I need your help guys. Thanks in advance. Here is the code for main Main Activity.java package com.aidforpcs.www.myfragmentexample; import android.content.Context; import android.support.v4.app.FragmentActivity; import android.support.v4.app.FragmentManager; import android.support.v4.app.FragmentTransaction; import android.support.v4.view.PagerAdapter; import android.support.v4.view.ViewPager; import android.support.v4.widget.DrawerLayout; import android.support.v7.app.ActionBar; …

Member Avatar
+0 forum 0

I add some codes in my android studio project after run it shows error class,imterface and enum expected and some other error so how to solve this error?

Member Avatar
Member Avatar
+0 forum 1

As what was stated on the header I want to implement either a "paint" or "eraser" function whichever feature more convenient for user to edit paint/censor unwanted parts of a photo displayed on a imageview before uploading it to a server in the edited format and a redo function if user makes a mistake while editing? How do I come about doing it, I've read relevant topics on Canvas, or FingerPaint but still puzzled on how to implement it based on the scenario in this link [here](https://drive.google.com/file/d/0B2rvGRbu0A83LU1pQjRicnNFS0U/view)? Thanks for any help rendered! idImage = (ImageView)findViewById(R.id.idImage); Bitmap bitmap = null; bitmap …

Member Avatar
Member Avatar
+0 forum 1

The End.