android

Droid's mediaserver dies on camera.takePicture()

On Motorola Droid, Firmware 2.1-update1, Kernel 2.9.29-omap1, Build # ESE81 When attempting to take a picture, mediaserver dies with a segmentation fault. I've tried putting takePicture in a timer and running it a few seconds after camera initialization to check for race conditions, but no change. Just calling Camera.open() doesn't ...

setOnItemClickListener not responding for Custom ListView

hi, I wrote a custom Adapter for a listview ,but when i tried implement click event for list item ,i found that it was not responding ,I will be glad if someone suggest me a solution. public class TourList extends ListActivity { .... setContentView(R.layout.tourlist); ..... getListView().setOnItemClickListener(new OnItemClickListen...

android supported devices

Hi all, i developed one application that should run on all the android supported devices.can you please suggest me different screen resolution of android os devices Thanks in advance Aswan ...

Ideal way to cancel an executing AsyncTask

I am running remote audio-file-fetching and audio file playback operations in a background thread using AsyncTask. A Cancellable progress bar is shown for the time the fetch operation runs. I want to cancel/abort the AsyncTask run when the user cancels (decides against) the operation. What is the ideal way to handle such a case? ...

SQLite in android

Hi, My android application uses an sqlite database and during first run it deletes some rows . The next time it runs it tries to do the same , but because the rows were previously deleted it fails . I use SQLite database browser to inspect the database ,after first run (when the rows are deleted) and I observe that the rows that no long...

Android connecting to Twitter

I'm learning Android and I'm trying to connect to Twitter and upload a photo in Android. How can I do this? ...

How to read and write UTF-8 to disk on the Android?

I cannot read and write extended characters (French accented characters, for example) to a text file using the standard InputStreamReader methods shown in the Android API examples. When I read back the file using: InputStreamReader tmp = new InputStreamReader(in); BufferedReader reader = new BufferedReader(tmp); String str; while ((st...

Android RelativeLayout fill_parent unexpected behavior in a ListView with varying row heights

I'm currently working on a small update to a project and I'm having an issue with Relative_Layout and fill_parent in a list view. I'm trying to insert a divider between two sections in each row, much like the divider in the call log of the default dialer. I checked out the Android source code to see how they did it, but I encountered a p...

Need help in using getScrollY() of ListView

Hi, I have the following code which recording the scroll Y position in my ListView whenever my activity is paused. protected void onSaveInstanceState (Bundle outState) { super.onSaveInstanceState(outState); int scroll = mListView.getScrollY(); System.out.println (" scrollY" + scroll); } But regardless where I scroll my ListVie...

Android singleline texthint

The setHint and singleLine settings don't seem to be able to work together. If my hint is longer than a single line and I have singleLine set to true, the editText box automatically spans to 2 lines regardless. Does anyone have a workaround? ...

Detecting SMS incoming and outgoing

Hi, I'd like to detect sms incoming and outgoing automatically from my application at background whenever this app is opening or not. how to code? ...

How to transfer SQLite db to web server on android phone

Hi, I have an application that creates an SQLite database and saves information to it over the course of a day. At the end of the day i want to export this database to a web server. Could anyone point me in the right direction for this? Should I use httppost or put. I have researched this myself online but there seems to be so many di...

can i use google maps data for my own app on android?

Hi, i want to know if i can use the data (for exaple a tour from point A to point B) and extract it for example to save the tour infos to an text file or post it somewhere or do whatever i want with it? i want to use maps as a database, so what are the restrictions, what am i allowed to do? ...

Running activity from remote service

Hi, iam trying to run an activity from diffrent package from my remote service: this is how i implement the service.java public class CurrencyService extends Service { public class CurrencyServiceImpl extends ICurrencyService.Stub { int CALL_PUSH_SERVICE_ACTIVITY=10; @Override public void callSomeActivity(int ...

How to connect to a SOAP webServices with Android

Hi everyone,I'm programming an application who must send coordinate and request to a WebServices this is my code: private String SOAP_ACTION = "getAllPositions"; private String METHOD_NAME = "getAllPositions"; private String NAMESPACE = "http://session/"; private static final String URL ="http://192.41.218.56:808...

Getting Json data into a list view

Hi, I have been searching for a way to get the json data from a URl (for example: http://search.twitter.com/trends.json) and display it in a listview. Couldnt get a perfect example to get it done. Can anyone plz help me out by getting the solution and providing a good example of how to do it... ...

How to pass object from one activity to another in android

Hi I am trying to work on sending an object of my "Customer" class from one activity and display on other activity. the code for the customer class : `package com.kaibuki; public class Customer { private String firstName, lastName, Address; int Age; public Customer(String fname, String lname, int age, String address) { firstNam...

Where is the documentation for Android SDK API 4?

Hi, I'm using Eclipse with the Android SDK. I installed The SDK platform Android 1.6, API 4 using Android SDK and AVD manager, but I can't find the corresponding documentation in the list of the available packages (there's only the doc for the API 7). Where can I find it? thanks jul ...

Android - cant read TXT files from SDcard on real mashine?

Hello! When I run the code bellow in the virtual android (1.5) it works well, TextSwitcher shows first 80 chars from each txt file from /sdcard/documents/ , but when I run it on my Samsung Galaxy i7500 (1.6) there are no contents in TextSwitcher, however in LogCat there are FileNames of txt files. My Code: public void getTxtFile...

Andriond send event from first activity and receive on the second.

Hello, I have two activities. The first activity display list of the users with short info. And after select some user I go to the second activity for display full info about this user. For send event I used startActivityForResult(); for receive event in socond activity and added public void onActivityResult(int requestCode, int ...