android

Store content in android market

Can I upload content(any type png/jpg) onto android market, which I could download while the application is running. ...

Fill spinner from cursor in android

Hi, i have searched for a awnser for this for a while today. It all looks so easy but i never get it to work. I want to fill a spinner with my cursor. I have been trying to use SimpleCursorAdapter for this as a lot of sites say i shall but i never get it to work. Show me just how easy it is :) Thanks for your time! My cursor Cursor cu...

android database leak found IllegalStateException

04-20 16:53:39.010: ERROR/Database(419): Leak found 04-20 16:53:39.010: ERROR/Database(419): java.lang.IllegalStateException: mPrograms size 1 04-20 16:53:39.010: ERROR/Database(419): at android.database.sqlite.SQLiteDatabase.finalize(SQLiteDatabase.java:1668) 04-20 16:53:39.010: ERROR/Database(419): at dalvik.system.NativeStart....

Creating a dynamic (video) Overlay on Google Maps on Android 2.1

I'm trying to create a map overlay for displaying a video stream (MJPEG) on top of a Mapview. Currently I've a standalone activity that creates a data thread for fetching MJPEG video frames. I'm using a handler to send a frame (as a Bitmap) from the data thread to the main activity which then updates the UI. I'm not sure how to impl...

Android emulator system partition no space from start

I got a wierd problem with android emulator, I have created a virtual device through Android AVD manager (newly created emulator with platform 2.1 and api level 7), I have tried with standard settings and with added hardware parameter for larger (256 mb) device ram size but nothing changed. I need to come files to the system partition t...

Detect if a table contains a column in Android/sqlite

So I have an app on the market, and with an update I want to add some columns to the database. No problems so far. But I want to detect if the database in use is missing these columns, and add them if this is the case. I need this to be done dynamically and not just after the update to the new version, because the application is supposed...

First run run after install.

Hello, In Symbian, if we set a parameter frri, we can make the appmanager to run the new application on completion of download and installation. Do we have any feature as such in android so that application will start as soon as it gets installed on to device. Thx. ...

Android Remote Service Keeps Restarting

Ok so I've built an app that uses a remote service to do some real time GPS tracking. I am using the below code to start and bind to the service. The remote service uses aidl, sets up a notification icon, runs the GPS and locationListener. In onLocationChanged, a handler sends data back to the caller via the callback. Pretty much strai...

Is it possible to start an activity in a different apk using startActivity on Android using the activity name or similar?

I have tried to write an Android application with an activity that should be launched from a different application. It is not a content provider, just an app with a gui that should not be listed among the installed applications. I have tried the code examples here and it seems to be quite easy to launch existing providers and so on, but ...

Application running triggers another application installation

My application is a trial version apk. Once the period is completed, can I initiate another application to be installed/downloaded from the android market ( purchasing process) which is a paid application using the current running trail application. ...

Broadcast Intent when network state has changend

Does Android broadcast an intent when the network state has changend, i.e. from GSM to Wifi? And if so what permission do I need and what is the intent action called? ...

Android emulator -dns-server usage

I am currently somewhat struggling to get the Android emulator to use a custom DNS server, which is running on localhost (127.0.0.1). As of now, I have tried various approaches trying to convince the emulator to use my DNS server, so far without success. In the end, it always boils down to the following error message: ### WARNING: can'...

Setting width of textview in a LinearLayout

Hi, I am using a header for a Listview. ListView header has three columns. Say a,b,c. I am using two LinearLayouts to design ListView header as shown below: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height...

Good way to cache data during Android application lifecycle?

Hello, keeping my question short, I have creating application with 3 activities, where A - list of categories, B - list of items, C - single item. Data displayed in B and C is parsed from online XML. But, if I go trough A -> B1 -> C, then back to A and then back to B1 I would like to have it's data cached somewhere so I wouldn't have to...

ContentObserver on Contacts.

Dear, I am using API level 3. My need is to track contacts update,delete and insert actions. i used ContentObserveron such like below: ContactObserver contactObserver = new ContactObserver( getApplicationContext()); Uri CONTACT_URI = People.CONTENT_URI; // Uri CONTACT_URI = Contacts.CONTENT_URI; also did ...

Is there a rule of thumb when porting iPhone graphics to Android?

I'd like to port my iPhone app to Android. The interface is constructed with artwork designed for 320x480 resolution. What steps do I need to take when I'm constructing the XML interface for the Android so that my GUI will be compatible with the different screen sizes (or at least the most popular ones...)? ...

Should I use vnd.youtube:videoID?

While playing around with the emulator, I noticed that when trying to view a YouTube video the browser gives an error saying it can not load the page at vnd.youtube:ngc978y6rCU?some=parameters. I don't have an Android device, but by this I can suppose that launching a VIEW intent with the data URI set to vnd.youtube:VIDEO_ID would launch...

Calculating the angle between the line defined by two points

I'm currently developing a simple 2D game for Android. I have a stationary object that's situated in the center of the screen and I'm trying to get that object to rotate and point to the area on the screen that the user touches. I have the constant coordinates that represent the center of the screen and I can get the coordinates of the...

Custom preference screen

Hi, I have a slider for the user to control the volume of my application. What I'd like to have is a icon or something else similar to "volume display" like in the next picture at the slider summary. Is this possible ? How could this be accomplished ? ...

Android: How would you make Buttons un-clickable for some period ?

I've got some Buttons that I want to make un-clickable (but still appear on the screen) until another process (thread) has finished its work ? How would you do this ? The goal is to avoid my users to keep clicking on this button and so, launching a new thread every time they click on it ... Thanks for your help. Hubert ...