android

Android different resolutions problem

Hi, I have 9 (vertical) radio buttons and they are all showing in default resolution (320x480) without problems . But when I'm trying in resolution for Htc Tattoo (240x320) the last radio button is hidden - there isn't space to be shown. How to make uniformly size ? ...

How to handle application upgrades from free to paid version while preserving any data

Here is the context. I want to have a free version and a premium version of the same application. When people buy the application, I want them to be able to "upgrade" without losing their data, i.e. the premium version should install over the free version. I want to use the same code base and just switch a setting to build the premium ve...

android 2.2 google map error

I used google.map api to develop a project which works well on android 2.1. But when I run the same project on android 2.2, it encountered some errors. The shown errors are -- AndroidRuntime FATAL EXCEPTION:main -- AndroidRuntime java.lang.NoClassDefFoundError:android.net.NetworkConnectivityListener -- AndroidRuntime at com...

AlertDialog Input Text

Hi, I'd like to use AlertDialog as a Login or pin code or password dialog. Here is my code - AlertDialog.Builder alert = new AlertDialog.Builder(this); alert.setTitle("Login"); alert.setMessage("Enter Pin :"); // Set an EditText view to get user input final EditText input = new EditText(thi...

Renaming column in Android sqlite database results in error

I've been modifying the Notepad tutorial for Android very subtly- all I did was rename the column from title to name: Before: public static final String KEY_TITLE = "title"; ... private static final String DATABASE_CREATE = "create table notes (_id integer primary key autoincrement, " + "title text not null, body tex...

Listing an application's activity and intent-filters?

I am interested in activating another application's activity. I know from reading the Android SDK that it's probably better to do this with an implicit intent. However, this activity doesn't reside in an application I own, so I don't know the action and category and data flags on the intent-filter. How can I examine an Android applicati...

How do I get preferences to work in Android?

I've really been struggling through this. New to Java/Android. I'm writing my first app and this is the first thing that has taken me longer than a couple days of searching to figure out. Here's the setup: It's a BAC calculator / drink counter: A formula is used to calculate the BAC. Here's the forumla: Bac = ((StandardDrinks / 2) * ...

Service exiting after last client unbinds, even though startService() called beforehand?

I have an app that has a client Activity and a long-running Service. The Service may be started by the alarm manager or by the Activity itself. The alarm intent calls startService(). The Activity calls startService, and then binds itself to the service so it can get information from it. When I back-button out of the Activity, onDestro...

Android hidden title bar comes back

When my app starts, the title bar is hidden. However, if I leave the app and then return (minimize or phone goes to sleep), there is a blank bar inserted at the top. Is this an intentional feature? How can I prevent it? It seems that the bar goes away after I press the menu key. This is the relevant line in the manifest file: android:t...

i am new to Flurry Analytics in Android, where can i find basic tutorials to work on it?

i am new to Flurry Analytics in Android, where can i find basic tutorials to work on it? ...

Download a file with DefaultHTTPClient and preemptive authentication

After I had a lot of problems with preemptive authentication , I got it finally working. Now the next problem. I want to get a file with it, but I don't know how. I thought the file data might be in the variable response, but it isn't. Any ideas how this might work? I'm trying it since days without success :( - Basically I'm trying to do...

Scrolling a ListView changes everything from White to Black

I have a custom list view and I want the background of the list to be white, so I do something like this which works great. listView = (ListView) this.findViewById(R.id.listview); listView.setBackgroundColor(Color.WHITE); The problem is when you scroll the list the background of all the list items changes to black, which looks horribl...

How to use arrays in addding numbers?

Hey Can anyone tel me how to use arrays in Android.I need to add the numbers given by the user...Pls help me ...

Launch app with specific locale

Changing the locale for a device is done in the settings, and can't be done by an app AFAIK. I know how to force my own app to a specific locale, described e.g. here: http://www.tutorialforandroid.com/2009/01/force-localize-application-on-android.html So now to my question. Can I force, programatically, the local of an activity that ...

android call an outside function from a thread

hi.. say for example I have this code in my activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); Thread cThread = new Thread(new Runner()); cThread.start(); } private NotifyMe(){ //do something here } and this is my Runner class: ...

how to detect whether an image,video has been captured from phone camera of Nexus G1.

I don't have a dedicated button in Nexus1.I want to detect whether an image/video is captured from the camera like if anyone captures an image then it should write to file that image has been captured. ...

Android ical4j example needed

Hi.. Can any one give me a proper tutorial to parse .ics file in an android app with ical4j. I am new in android app. So a detail example will be very helpful. Thanks in advance. ...

How to Read MMS Data in Android ?

I want to read MMS data i have seen the part table in the mmssms.db where the mms entries stored i am using cursor to and i want to know the appropriate URI like i am using "content://mms-sms/conversations" and the Column names of "Address"(Sent to), "Text" or "Subject" and "Data" column name of image. i have seen the schema of mmssms.d...

Tab widget example not running

I'm trying to reproduce the tabwidget example (http://developer.android.com/resources/tutorials/views/hello-tabwidget.html). I'm not really sure what's the problem, I got no errors while compiling, but i cannot see the application on the emulators screen. It would be excellent if maybe anyone could have a look at my classes and tell me ...

Android 2.2 - and exchange password policy enforcement

Hi, In Android 2.2 site (link text it's written: Improved security with the addition of numeric pin or alpha-numeric password options to unlock device. Exchange administrators can enforce password policy across devices But while I'm using N1 with 2.2 and try to connect to my company exchange server it didn't enforce me to set a passwor...