Posts by Leonardo Saldanha • 369 points
11 posts
-
0
votes1
answer4109
viewsQ: Converting char vector to string - C++
#include <iostream> #include <string> #include <vector> using namespace std; int main () { string vet[10], aux; std::vector<char> name; int count=0, sum=0; while…
-
5
votes5
answers13518
viewsQ: Hide the keyboard
As soon as the user clicks on one of EditText from my Android app, the keyboard appears, however, it does not disappear when you finish typing and click off it. I would like to know which method…
-
1
votes1
answer1112
viewsQ: Set at least one number in Edittext
My question is this:: Is there any way to prevent the click of a button if an Edittext has no number at all? I was able to limit minimum and maximum values (0 to 255), but I could not find a…
-
2
votes2
answers1107
viewsQ: Update the value obtained in an Edittext
Next, I’m having a problem taking the value in an Edittext and displaying it in a Textview. The value displayed when using a string, is "null", and when using int, is 0. I believe this happens…
-
0
votes2
answers160
viewsQ: Nullpointerexception when creating a View on Android
I’m creating a Activity on Android, whose code is here, and I’m getting a NullPointerException near the line final TextView txtResult = new TextView(this); I got the following dump from the stack:…
-
1
votes2
answers222
viewsQ: Problem of cursor positioning
Logcat is accusing a problem of NullPointerException, but I can’t identify it. From my point of view, it’s right. I know there’s a problem in lines 34 and 39 of ContactRegister that lead to…
-
1
votes1
answer1413
viewsQ: Error - in such column
03-21 07:25:47.740: E/SQLiteLog(796): (1) no such column: name1 03-21 07:25:47.750: E/data(796): Error while searching contacts: android.database.sqlite.SQLiteException: no such column: name1 (code…
-
-5
votes1
answer377
viewsQ: Error - Nullpointerexception
03-20 10:35:20.250: I/Process(897): Sending signal. PID: 897 SIG: 9 03-20 10:35:25.870: E/SQLiteLog(914): (1) no such column: name 03-20 10:35:25.870: E/data(914): Error while searching contacts:…
-
0
votes1
answer313
viewsQ: Error - You must Supply a Resource ID for a Textview
03-17 08:31:32.283: E/ArrayAdapter(1085): You must supply a resource ID for a TextView 03-17 08:31:32.283: D/AndroidRuntime(1085): Shutting down VM 03-17 08:31:32.283: W/dalvikvm(1085): threadid=1:…
-
5
votes9
answers17662
viewsA: Error: R cannot be resolved
This is a common mistake that can come from several different sources: Error on one of the Xmls (even if it does not accuse); Do not save before Clean/Build; Any errors preventing automatic…
-
5
votes1
answer1988
viewsQ: Multiple layouts in one Activity - how to use?
As in this passage: @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.addcontact); imageButton01 = (ImageButton)…