android

onClick won't fire on ImageView

Hi everyone, I have 3-4 activities in the application and all of them have some event listeners that work nicely. However only on one activity i simply can't get the event handling to work. I tried the solution from this thread:http://www.anddev.org/view-layout-resource-problems-f27/ontouch-not-called-t16578.html It doesn't work for me....

How can I access user-installed keys and certificates from my Android app?

I've been struggling to consume user installed identity CA certs from a p12 file on an SD card. The certs and keys are installed using the Secure Credential Storage (Location & Security > Install from SD card). I haven't found any documentation stating the location if the keys and certificates once imported. I tried to create an inst...

Update Android SurfaceView on-the-fly with new elements

I have a database filled with records in the following format: . What I want my application to do is select records from an external database, and display those records on the phone screen using a SurfaceView. Currently, I have an Activity, and a Service responsible for the record-gathering portion of the application. The Activity pass...

Reason for getting Unknown URI content

Friends, I am facing a problem in inserting sqlite database table, 08-06 00:59:44.644: VERBOSE/Error(2407): Detail java.lang.IllegalArgumentException: Unknown URI content://com.fsp.jackrobie/jack_robie Here my code for insert public Uri insert(Uri uri, ContentValues values) { Uri newUri = null; try{ SQLiteDatabas...

Android Intent Filters for VIEW/EDIT/INSERT Contact

Hi, I've been trying to find one or all of the right filters. Does anyone have them? Down at the bottom you can see the logging output of the intents. Perhaps they aren't public? Have tried the following in my code to no avail... <receiver android:name=".ContactsBroadcastReceiver" android:label="@string/broadcast_receiver_name" a...

How to load only markers that's currently visible on the screen (Google maps on Android)

Hi, Using Google Maps on Android does anyone have any ideas on how to load only markers that would be displayed on the current screen? I'm thinking about sending a request to a web service that returns the lat/lng for the relevant markers. But what would the parameters be that I could use to calculate if a given lat/lng is within the s...

Context Menu Customization

I'm trying to return a list of addresses obtained through: addressList = geocoder.getFromLocationName(sSearchPath,5); I have a contextmenu displaying the results, however the text it too large and does not wrap content, it just travels off the window. How can I make the context window appear more like the Google maps navigation conte...

Crazy RatingBar

Hi, I'm trying to play around with a RatingBar, but something is really wrong. <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" > <RatingBar an...

Android 4x2 widget

Hi all, Looking at the Facebook widget I realized its a 4x2 cell and this isn't one of the standard sizes. I have tried to re-create a widget of this size (either as 320x200 or 294x146 px) however the widget doesn't look good on all devices. The widget layout is : <?xml version="1.0" encoding="utf-8"?> <!-- Portrait --> <RelativeLayo...

Android TextView respond to html <a> clicks

I have formatted data with commands embedded with tags. I use the HTML class to populate the TextView. Is there a way to intercept the click on the link and get what was clicked? Html.fromHtml("<a href='CMD:Bahai'>Some Command Link</a>"); ...

Programatically enabling/disabling screen rotations in Android.

I have an app which displays a large amount of text for the user to read. I've found that when reading while lying down, I get annoyed that the screen rotates even though my head and the screen are aligned. I do not want to set this to be permanently in portrait mode, so I think this would preclude an approach of setting the android...

I don't know why I'm getting an out of bounds exception!?

Hi I don't know why this is generating an ArrayOutOfBoundsException! It's likely I've overlooked something because I'm so tired but if someone could tell me what is wrong I'd appreciate it. Thanks. // array declaration public int CircleLeft[] = new int[mIPAWidth]; // this is my loop that generates the error: for(px = 0; px <= mIPAWidt...

How can I make my application as home application

I have a wizard application that I want to make Home application. How can I convert regular application into a home application. ...

Can a backgrounded Android app take screenshots of the currently active screen?

I'm new to Android development, and I was wondering if there is a way to have an app take a screenshot of the currently active screen, do some processing on the screenshot (which would be internal to the app and temporary; I don't want it in the photo gallery), then communicate with a remote server over the Internet? I am of course l...

How to capitalize a the first letter of text in a TextView in an Android Application

I'm not referring to textInput, either. I mean that once you have static text in a TextView (populated from a Database call to user inputted data (that may not be Capitalized)), how can I make sure they are capitalized? Thanks! ...

Having issues with centering text in TextView within a region...

Hi, I'm having issues with TextViews and centering the text within the text region. Specifically, I have a TextView, but when I have text inside that contains letters that straddle down the bottom margin (i.e. p, g, q, y, etc), those letters are getting cut-off. I'm trying to center the text within the region but haven't had much luck...

How to create equalizer for android

Hello. I want to create simple equalizer for android. How can I do it? Try to find some methods in MediaPlayer class. But all my attempts failed. ...

How to connect android to a database server

Is there any sample? I have my android application and I need to connect to mysql server on my machine, what is the best way? I should not use jdbc, explanation here link text And should go for: DefaultHttpClient httpclient = new DefaultHttpClient(); But there is no example in how to open a connection or excute a simple sql statem...

Android Demo's aren't appearing in simulator

I'm trying to get my feet wet with Android development. I downloaded Eclipse, and setup the ADT. When I create a project from existing source, I choose the demo projects (API Demo) and compile + run. The simulator pops up but I can't seem to find the API Demo application. How can I get this up and running? ...

Android2.2 :How to enable speaker and headset at the same time?

I am to do user testing on my app that can enable user use headset and tester listen to the sound from speaker also. Any idea how to do that? setSpeakerphoneon(true); seems not work thanks! ...