Posts by Jeiferson • 521 points
29 posts
-
1
votes0
answers31
viewsQ: onShowFileChooser() only works once
I have an Android application consuming a web page and implementing some functionality for the user. The problem appears when I try to attach media files from Android device to send to server more…
-
2
votes1
answer272
viewsQ: I cannot decrease the size of components . form-control
Hello, I’m trying to decrease the size of components that use class. form-control of bootstrap 3 but when I try to set the width of the components to the value "auto" it generates a spacing between…
-
2
votes1
answer60
viewsA: How do I access the text size (Texview) and compress the text box (Textview) via code?
To get the text size via code use: seuTextView.getText().length(); To get the font size of the text via code use: seuTextView.getTextSize(); I hope I’ve helped. Att. Jeiferson…
-
3
votes2
answers331
viewsA: String Statement
What you want is called two-dimensional matrices or vectors, I found in this link a very broad explanation of their functioning. But in short, you can declare a 2-by-4 (8-element) two-dimensional…
-
0
votes0
answers69
viewsQ: Custom actionbar does not take up the entire screen width
Well, I was trying to customize my Actionbar, it worked, but it turns out that it doesn’t fill the entire width of the screen, it’s as if it was superimposed on the old one, to better understand…
-
1
votes1
answer54
viewsQ: Error when trying to set custom Actionbar: java.lang.Nullpointerexception
I’m trying to customize my Actionbar but whenever I try to emulate the application it closes and returns me the following error in Logcat: 01-07 16:21:57.092 1388-1388/br.com.jeiferson.agenda…
-
1
votes1
answer915
viewsA: How to change the size of an Android imageView via code?
You can try that code: ImageView imageView = findViewById(R.id.dl_image); LayoutParams params = (LayoutParams) imageView.getLayoutParams(); params.width = 120; imageView.setLayoutParams(params); Or…
-
4
votes1
answer1002
viewsA: How do I get names of cities that are around me with API on a remote server?
I found a post that combines Google Maps Geocoding API with Geonames.org API to do what you want, follow below the code . php $geocodeObject =…
-
0
votes1
answer179
viewsQ: Could not open '/sys/class/power_supply/genymotion_fake_path/present'
I installed the emulator Genymotion in Android Studio, but it happens that when I run my app in emulator it returns me the following error: Could not open…
-
0
votes1
answer576
viewsQ: Error: java.lang.Illegalargumentexception: column '_id' does not exist
Good people, I was developing an app in order to learn where the goal was to register users in an Activity and another to be able to view all registered users through a listview. It turns out that…
-
0
votes6
answers18836
viewsA: Removing Titlebar from the android app
Try to change the theme of your Activity to: android:theme="@android:style/Theme.Holo.Light.NoActionBar.Fullscreen" Att. Jeiferson
-
1
votes1
answer108
viewsQ: Help to Compare ID to String
Good people, I’m developing a simple application that when started is displaying random images and text on the screen just for learning and what I have so far is this: package br.com.appteste;…
-
3
votes1
answer216
viewsQ: How to compare Drawables?
Guys, here’s the thing... I wonder how I see if the file that this set in the Imagebutton is equal to such drawable. To make it easier I’d like to do something like this: final ImageButton imgBt =…
-
1
votes2
answers1344
viewsQ: How to set random images in Imagebutton
Guys, I’m trying to make every 0.5s a random image of the folder drawable be set in mine ImageButton but I’m having problems the way I did. I tried to do it this way: I put the following names in…
-
0
votes0
answers209
viewsQ: Consuming a PHP Webservice
I set up a Webservice in PHP and need to know how to consume it, whenever I do a search on it it returns me like this: All Alerts: get_all_alerts.php {"table_alerts":[{"id":"1",…
-
2
votes1
answer985
viewsQ: Error when converting String to Jsonobject
I am trying to develop an application on android that consumes a Web-Service but whenever I try to run a query in the Database it returns me this error: Error Parsing data org.json.Jsonexception:…
-
1
votes1
answer340
viewsQ: Web Service returning invalid value
Good people, recently I asked a question with the title: Application displaying this error: Error Parsing data org.json.Jsonexception But by researching I came to a different conclusion in which I…
-
3
votes5
answers1721
viewsA: Is it possible to change the type of the variable in Java?
Try it like this: double x; int newX = (int) x; Being newX the result of the conversion and (int) x to double that is being converted...…
-
0
votes1
answer704
viewsQ: Application displaying this error: Error Parsing data org.json.Jsonexception
I was trying to make an application for android with connection to Mysql through webservice and has been giving some problems, so I could solve, but this appeared, when I try to see the products…
-
0
votes2
answers162
viewsQ: Error trying to insert values in Mysql
Good person, I was trying to make an application that inserts products and allows you to view it on mobile through database, but when I try to create the product the application closes and it…
-
0
votes2
answers5338
viewsQ: Android connection to Mysql
Well, I got a free hosting from the site Hostinger Ai configurei o Mysql certinho la, but would like to know if it is possible for my android application to connect to this database? and if yes how…
-
0
votes1
answer113
viewsQ: Error trying to use Mediaplayer
I tried to elaborate a Button that when pressed performs a sound, but I know how to import that sound and I don’t know how to locate the Raw folder, when I try to use that line: mpSongButtons =…
-
0
votes1
answer1256
viewsQ: Error trying to connect to a local Mysql database
I am having problems trying to access a local Mysql database, I am following this tutorial. My file MysqlConnect.java: package br.com.alerts; import java.sql.Connection; import…
-
3
votes2
answers437
viewsQ: Closing Previous Activity makes the app faster?
I was developing an application for Android and I came up with a question: In my main class MainActivity i have the function setContentView that initializes my screen, but if I want to open other…
-
3
votes1
answer428
viewsQ: Error trying to create a database connection (Mysql)
I tried to make a connection to the Mysql database using AsyncTask, but is giving error in the class responsible for the connection, the MysqlConnect: The constructor Log() is not Visible I’m…
-
4
votes2
answers5266
viewsA: I can’t remove the title bar from the android app
We have many ways to do this. One of them is by code, just add the following line in the method onCreate: requestWindowFeature(Window.FEATURE_NO_TITLE); Thus remaining: @Override protected void…
-
0
votes0
answers86
viewsQ: Error when trying to access another screen using a Boot
My problem is this, I have my main screen that contains a button to access another screen, the code I’m using to make this call is: btRegister.setOnClickListener(new View.OnClickListener() {…
-
-5
votes4
answers2193
viewsQ: How do I search a value within a String?
I created a EditText for the user to enter a value, and as soon as they click the search button on String the value entered by him, but I would like to know how to search some value within the…
-
-1
votes1
answer785
viewsQ: How to create a search filter for a Three-Dimensional String?
I have a ArrayList of the kind String Three-dimensional: String[][] And I would like to do a search system that filters the values, example: String[][] table = {{"Ronaldo","32","Atacante","Sao…