android

android imageview onClick animation

hi. I guess this is kind of an odd question but i have tried setting onClicklistener on an ImageView and it has worked. But the problem is that the user cannot sense the click. I mean if some of u have worked on other mobile environs(like apple iphone) then wen we click on a Image in other environs then it gives an effect on the image so...

android cropping drawable

hi friends... I have a small project in which i download images from internet in the form of drawable and use them in Imageview for which i have provided functionality similar to an Imagebutton but without the gray edges. The question is that is there any functionality in Android(similar to iphone) by which we can crop the drawable fro...

delete a file from android application

How can i delete a file from android application.Is the same way that we use deleting a file in java or we have to use different way? ...

adb cannot find my device for Android debugging. Why?

I installed Windows USB Android SDK driver for the Android Dev Phone 1 I enabled all the debugging modes and stuff on the phone. It even says...USB debugging connected. When I type adb devices , it shows me only my emulator , and not my phone. It doesn't seem to recognize my Android Phone as an adb device. Why is that? ...

How to use non-standard (hidden) API classes?

Hi, I'm fairly new to Android and have gone through the basic tutorials. I thought I'd dig a little deeper and downloaded the source code to some of the "native" Android apps, like IM, Email, Voice Dialer, etc. In importing the source of these native apps into Eclipse, I found that they reference classes that are not in the 2.1 API, i...

Android Textview Italic and wrap_contents

I am using 3 italic textviews with different colors <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:id="@+id/submittedBy" android:paddingTop="10dip"> <ImageView a...

display current time and date in android application

How to display current date and time in android application? ...

How to draw charts in Android?

I want to draw charts like pie charts to display stats in my Android app. As Android doesn't support Swing and AWT, i wonder how can i draw charts in Android? Please note that i don't want to use a third party tool. ...

How can i get the album art from MediaStore?

Hi! How can I get the album art from MediaStore? I try something like: String[] projectionImages = new String[]{MediaStore.Audio.Albums.ALBUM_ART, MediaStore.Audio.Albums.ALBUM_KEY}; Cursor c = contentResolver.query(MediaStore.Audio.Albums.INTERNAL_CONTENT_URI, projectionImages, null, null, null); if(c != null){ c....

Android: Forcing a WebView to a certain height (or triggering scrolling for a div)

Hi, I am building an app which contains an input form and a WebView. The project is available at http://code.google.com/p/android-sap-note-viewer/ The WebView will render a website based on the input and this page has a DIV with the main contents (could be hundreds of lines). I have no control of the contents on the website. Android W...

Android: findviewbyid: finding view by id when view is not on the same layout invoked by setContentView

Hi all! I have and activity MyActivity that extends from MapActivity. In the .xml file containing the layout I can only include the MapView: However I do neet to find another view that is located in another .xml file. Unfortunately, findViewById returns null. How can I get the view I am looking for? Thanks a lot in advance! ...

How to kill a Service by another Activity?

Activity 1 starts a Service, using the standard Intent. Activity 1 starts Activity 2. Then, Activity 1 gets finished(). Now, there's only Activity 2. How does Activity 2 kill the Service, since that Intent was generated in Activity 1? I don't want to pass the Intent everywhere... ...

How can I store data against specific contact ID?

I want to store some additional data for each contact on Android. I would have in mind creating my own database table for it, and then bind them to the real contact via a unique id. I am wondering if Android has built in functionality to store additional data against contacts? EDIT 2 Is there a defined field for birthday of the contact...

How to issue a confirm (yes/no) message of a Android task?

I want to ask the user if he agrees to continue launching a task, how do I issue a confirm window having Yes, No buttons? ...

How to change background color of custom xml file in android

how to change the inner color of my xml file.It has default color as black only.how to change to other color.i have gn by xml file below .xml file is used for creating border,but i cant change the background color.Need help on this Regards Gomathi sankar ...

Integrate Mapview into a tab/Integrate overlays/markers.

I need some help integrating a mapview into a tab and integrate overlays/POI. Current code: TravelBuddy.java package com.travelbuddy.android.jappapps; import android.R; import android.app.TabActivity; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.widget.FrameLayout; import andro...

Listen to ActivityManager events?

Hi, is it possible somehow to listen to the events of the ActivityManager, e.g. when activities are started? Does the ActivityManager send broadcasts? I havn't found anything indicating that it does. What I basically need to do: I want my app to launch one of my activities whenever a certain (thirdparty) app is launched/takes focus. Pr...

How do I set a background image for each item of ListView in Android?

<?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="?android:attr/listPreferredItemHeight" android:padding="6dip"> <ImageView android:id="@+id/icon" android:layout_width="wrap_content" ...

how to change button text dynamically for every 3 sec in android?

Hi all,in my application i want to change button text for every 3 sec. ...

Android - Using method from a Service in an Activity?

I have the folowing method in a Service in my appplication: public void switchSpeaker(boolean speakerFlag){ if(speakerFlag){ audio_service.setSpeakerphoneOn(false); } else{ audio_service.setSpeakerphoneOn(true); } } So my question is whats the best and most effective way to be able...