android

How can I detect any key pressed (numeric, alphabet) event in Android for EditText

I have inherited EditText class an made my custom class, MyEditText. and want to detect key pressed(say 'a', 'b', 'c'... '0', '1', '2'... etc.) event in Android. How? It seems overridden method onKeyDown(int keyCode, KeyEvent event) is called when 'back', '\', '/', 'DEL', '@' keys are pressed, but not for any numeric or alphabets. ...

Android contatcs vcard API

Is there any android API to extract contacts in vcard 3.0 format ? I have come across an open-source vcard project android-vcard but in the usage Example the following comments are mentioned. Important: If you are developing application for Android device, you don't have to use this library, because it is already included in the under...

setting status of gtalk through android application

Hi, I have an android application working right now. I would like to add a new feature in that -chat status. I expect its working like this: when i set status to available or invisible, it should set my gtalk status with the same. Is that possible in any ways? ...

"SQLiteDatabase created and never closed" problem.

Hi, I have the same problem as in http://stackoverflow.com/questions/2280345/sqlite-database-leak-found-exception-in-android - I get "SQLiteDatabase created and never closed" although I close all my databases and cursors. But I am new to java, can someone please help me implement the solution in my context? since I am not using my own p...

Andrioid Button set Background to Transparent Color

How can I set the Background for a button to a transparent Color, like transparent Blue for eg, instead of a solid blue? When I use button.setBackgroundColor(Color.BLUE) it sets it to a solid blue. Thanks Chris ...

Android separate code into packages

I'm just getting into my first android application and just wondering what the convention is here? Is it more organised to separate my code into various packages? For example. com.myfirstapp.activity; com.myfirstapp.database; I was thinking of doing this as a way of organising my code with database helper files for example kept it .d...

Background tasks and activity

Hi, Has anyone any idea on how to solve the generic problems related to starting a task in background from an activity and when the task is finished posting the result to the activity that created ? (the activity might get destroyed in the meantime due to a orientation change ,or receiving a call , or might be in the process of destroyi...

Make a ViewGroup clickable on Android

I have a ViewGroup (LinearLayout) which contains a couple of TextViews and one ImageView. I want to make this entire group clickable. I tried something like this: viewGroup.setOnClickListener( new OnClickListener(){ @Override public void onClick() { //do stuff } }); However, clicks on the T...

Access SQL Server 2008 from Android?

I know there is already a question like this, but I have found this page on the Android Developemt site: http://developer.android.com/reference/java/sql/package-summary.html which seems to suggest that it is possible to interface to a SQL database. If this is possible then could someone please show me how it can be done. ...

android sqlite exception:java.lang.IllegalArgumentException: column '_id' does not exist

Hi all I created a sql lite database with the following columns: static final String dbName="demoDB"; static final String tableName="Employees"; static final String colID="EmployeeID"; then public void onCreate(SQLiteDatabase db) { // TODO Auto-generated method stub db.execSQL("CREATE TABLE "+tableName+" ("+...

Java code reuse through Inheritance when generics are involved (List in particular)?

I have very little knowledge of generics other than how to 'use them'. In my app I have various ListView Activity that seem to share similar methods and variables and have the exact 'algorithm' in the sense that the steps performed are all very much the same. For example in my onCreate method I call a method to add a footer, start a pr...

Compile Fastboot on windows

Specify me the steps to compile fastboot under cygwin to generate fastboot.exe for windows ...

View refresh issue on Android 2.0+

I have have an Activity where I would like to hide some elements based on user selection of certain options on same screen. I'm using View.GONE to complete take view off the screen layout if particular option is selected. So this results in some of the UI components move upward. And this seems working fine till Android 1.6. When UI comp...

Android/Java: Simulate a click on this webpage.

Hello all Last year I made an Android application that scrapped the informations on my train company in Belgium ( application is BETrains: http://www.cyrket.com/p/android/tof.cv.mpp/) This application was really cool and allowed users to talk with other people in the train ( a messagery server is runned by me) and the conversations wre...

change image onConfigurationChanged

Hi all Is there a way to change ImageView drawable with its corresponding drawable for landscape mode without destroying the whole activity. I tried to set the drawable again in onConfigurationChanged callback but it doesn't work. Something like this @Override public void onConfigurationChanged(Configuration conf) { super.onConfigu...

Android and java Association

Can anybody please tell me that how closely Android Application Development is associated with Java. That is, is it possible for a person working in Android Development to work on Core Java or J2EE or J2SE ever? Let me make my question a bit more clear: " As Android is based on Java, but does it depends on Java so well that a person fro...

Strange problem of apostrophe in communicating with PHP script from Android

Hi, I am communicating with PHP web services in Android application. All the requests send from android are encoded with UTF-8 and the php scripts decodes it with utf-8. But when any request is send with apostrophe ' the decode function of php doesn't seem to work the way it should. For example, if I send the request as "Today's Hor...

Android - Changing GridView text color and styling.

Hi I am very new to android development. I have a activity with a GridView. I need to change GridView's text color and change each row's background color. How can I do this ? Thank You in advance. DineshNS ...

How can we set the border to a list item in list view

By Default in the Listview,focus will come on the list item. Instead of that, can I get only the border to the list item? I can achieve this by using a transparent image as a list selector. Is there any other simplest way to achieve this requirement? ...

How to webview swipe gesture detect with multitouch zooming enabled withing a flipper

So is there a way for a webview control to detect a swipe while capable of doing multitouch zoom and having build-in zoom controls? ...