Questions tagged as 'android'

2
answers

How to read a txt file store value in integer type?

I'm using this example: try { AssetManager assetManager = getResources().getAssets(); InputStream inputStream = assetManager.open("nome-do-arquivo.txt"); InputStreamReader inputStreamReader = new InputStreamReader(inputStream);...
asked by 03.03.2016 / 19:51
2
answers

How to read sdcard CSV file?

Currently I read a csv file from the assets folder with the following code: String arquivoCSV = "clientes.csv"; AssetManager manager = context.getAssets(); InputStream inputStream = null; try{ inputStream...
asked by 07.03.2016 / 15:10
2
answers

What kind of database to use and how not to create many activities? [closed]

I want to create an application, which will use barcode recognition, this bar code will lead to a screen on the medicine, the part of the database I do not know which to use, because I have never used it, the screen I intend to create one reuse,...
asked by 25.12.2018 / 22:22
1
answer

Infinite loop when retrieving and writing data in Firebase

I'm new to Android and had a problem retrieving a data from Firebase and recording again, I know the reason for the infinite loop but I do not know how to fix it. public static void setVoto (String candidato){ votoFirebase = referenciaData...
asked by 26.07.2018 / 20:28
2
answers

List always returns only the first row of the bank sqlite [closed]

I have a list, which shows all sqlite bank data, image path, latitude and longitude, but in the list only changes the image path, latitude and longitude always stays the first record. public List<Foto> todasFotos(){ List<Foto>...
asked by 27.09.2016 / 16:59
1
answer

How to show message that the app is processing

I have a method that is exponentially time complexity and it takes a while to process, a matter of thirty seconds on average. However, during this time, the app hangs and gives no sign of life. I wanted to show a wait message, I tried to use Toa...
asked by 27.02.2018 / 17:01
1
answer

findViewById (2131230729) What are these numbers?

I'm analyzing a class from an Android app project, I'm new and I did not understand these numbers within the findViewById(2131230729) , within the parenthesis it was to have R.id. "layout" how do I go through that number to figure out the l...
asked by 20.03.2018 / 16:58
1
answer

Start an activity from an item in the bottom navigation (menu bar)

I have the activity main and a bottom bar navigation with 4 items. When I start the application, it starts, it shows the activity of the first item. I wanted to get it "started" from item 3. Is it possible to do this? How?     
asked by 18.02.2018 / 05:03
1
answer

Timeout on task execution Asynctask

How do I limit the execution time of a Asynctask and return a warning when the limit is reached? The method looks for a json from a webservice, but it may be off the air, and when that happens the app will try for a long time until it...
asked by 15.02.2018 / 11:06
2
answers

String Format CPF on Android

I have a CPF variable that is populated with a value that comes from the database (% w / w). Before giving 11122233344 , I need to be formatted as setText() . How could I do this?     
asked by 21.02.2018 / 14:11