android

How come MapView shows less then Map application?

I have a com.google.android.maps.MapView in my application. When using the normal view I do not get any data in Jerusalem and its surroundings. When scrolling to the same location with the Maps app or the maps.google.com webpage the place is rich with mapdata. Is there a (known) difference between the Map API view and the Google view of...

delete specific row from database

Hi, I`am trying to delete a specific row in database. i am deleteing by using this query: Uri myUri = Uri.parse("content://com.idan.datastorageprovider/maps"); this.getContentResolver().delete(myUri, "ROUTE_NAME="+routeName,null); in my database i have 2 columns: ROUTE_NAME,ROUTE_PATH. and i want to delete a row by the column...

Is this a standard android component?

The "Top paid", "Top Free", "Just In" buttons (with green selection indicators) in the picture below...Are these standard components that I can use in my Android application? I can't seem to find them within the SDK and yet I've seen them here (in the market) and within the Seesmic Twitter Android app. I would like to use such and effe...

How can android find a certain activity or service based on a given Intent?

Suppose that I installed app A and app B, app A has a main activity, and app B wants to show that activity by sending a intent. My question is that how android knows I have installed app A and is able to map the intent to its activity? Is there any windows-registry-like store saving such information? Thank You ...

draw object/image on canvas

Is there another way to draw an object on a canvas in android? This code inside draw() doesn't work: Bitmap bmp = BitmapFactory.decodeResource(getResources(), R.drawable.pushpin); canvas.drawBitmap(bmp, screenPts.x, screenPts.y-50, null); Well actually, it's working on my 1st code but when I've transfered this ...

HttpsURLConnection and intermittent connections

I'm hoping someone could help me out with intermittent connections I'm getting using code with HttpsURLConnection. The code I'm using is below: HttpsURLConnection conn = (HttpsURLConnection) url.openConnection(); conn.setReadTimeout(10 * 1000); if conn.getResponseCode() != 200) { Log.v(TAG, "error code:" + c...

Is possible to set an listener just for a part of a custom view?

Hi! I want to create a custom view (extends View) which contains an image and a text. Is it possible to set an listener just for image if i use canvas.drawBitmap(imageBitmap, ...) method? Thank you! ...

Android newbie problem: restarting an application

Hello, I have an Android app that works fine the first time you run it. However, when you press HOME (so it pauses), and restart it from the home screen all I get is the music restarted. I've not yet got to the stage of saving/restoring states yet (will do soon!). It seems that the main update thread is not resuming. It calls onRestar...

self call onUpgrade method

How can i call the onUpgrade Method of the database? Background of my question: I do a backup on the sdcard of the full database. And the user can restore this database. But if in the meantime (beetwen backup and restore) an app update has made changes to the database i get a problem on restoring. The new colums are not there after res...

How to set background color of a View

I'm trying to set the background color of a View (in this case a Button). I use this code: // set the background to green v.setBackgroundColor(0x0000FF00 ); v.invalidate(); It causes the Button to disappear from the screen. What am I doing wrong, and what is the correct way to change the background color on any View? Thanks. ...

How to look-up a contact's name from their phone number on Android?

Hi all, I am trying to get the sender's name from the contacts database using a content provider. The problem is I don't know how to implement it. Like now I can only pull the phone number from the smsMessage. I need to check to see if the phone number that is calling is in the users contacts first and if it is display the name if it i...

Newbie cannot program Hello world app

I recently downloaded Eclipse (Galileo), the Android SDK and Java. I followed instructions to write the "Hello World" app http://developer.android.com/guide/tutorials/hello-world.html from the developers'webpage and ran the app. a window opens with a phone screen that reads "ANDROID" on the left and a keyboard image on the right. It do...

adb error: unable to parse adb version

Is there anyone who has had any problems using WIN7 and Eclipse? Everytime Eclipse starts this error always comes up: UNABLE TO PARSE ADB VERSION If you try and run/debug the app from within WIN7, The connection to adb is down, and a severe error has occured. [2010-01-29 19:00:17 - app name] You must restart adb and Eclipse. [2010-01-...

Android Frame Animation

Hi, I would like to know if it is possible to remove one of the frames I added using addFrame in Android? Thanks Kelvin ...

Can I get Uri of image file from its name?

There are some image files, and I want to get Uri of these image files. In my code, I only know path and file name of image files. How can I get Uri from its path and file name? ...

"Something wrong here, didn't expect PACKAGE to be resumed" error in andorid LogCat

I have an Android app modeled after the LunarLander example by Google. I am debugging it on a real device, (Motorola Droid) with Android 2.0. When the orientation changes, the program crashes on a null pointer Exception. Logcat from just before crash: 02-01 00:24:27.956: DEBUG/nate(8358): Starting Game 02-01 00:24:36.878: DEBUG/dalvi...

Android canvas to jpg

I draw 2d images on the canvas using the following tutorial. http://www.designerandroid.com/?cat=3 I want to save what ever dispalying in a canvas as a jpg image, how can i do it ?? Thanks in advance. ...

In which format the contacts are stored in android?

Hi I want to know in which format the contact details are stored in android mobile or emulator.If any body knows the answer please help me. ...

How to use Bluetooth in Android emulator?

Hi I want to create an application based on bluetooth operation in android.I am using the following code BluetoothAdapter adapter=BluetoothAdapter.getDefaultAdapter(); the adapter is returning null value, which means the android emulator is not having bluetooth capability. i am using android 2.1 the latest version of android.Anybody...

freeze on sending certain bitmaps to activities

Basically I receive the Image's URI from the Gallery, then created a Bitmap and want to send to another activity for displaying: Uri imageUri = intent.getData(); mBitmap = MediaStore.Images.Media.getBitmap(getContentResolver(), imageUri); Intent intent = new Intent(TakePictureActivity.this, PreviewActivity.class); intent.putExtra(EXTRA_...