While programming I kept getting dns failed exceptions. The error was called due to not having the proper permission for using the internet in my android manifest. <uses-permission android:name="android.permission.INTERNET" />

Lazy Loading GridView

I just added sample code showing one method of lazy loading images in a GridView. I used thread, handler, and the looper classes. It starts by displaying a GridView with a ViewSwitcher that initially displays ProgressBars for each image. Then as the images are sequentially loaded the ViewSwitcher switches to the loaded ImageView. Check it out here. Screen shot:

getAdapter throwing java.lang.ClassCastException

I had used addHeaderView method to add a header to my listview. But when I went to retrieve my adapter I kept getting class cast exceptions. I was very mystified until I looked at my recent changes. I commented out the addheaderview line and viola it worked. A bit of googling directed me to this useful link about the topic.

Custom ListView Layout

I came across this while trying to figure out how to make a custom list view layout. So far it works really well. Very simple straight forward example.

notifyDataSetChanged not working for ListView with CursorAdapter

I was running into problems where my ListView was not updating after calls to notifyDataSetChanged. Despite the Cursor.isOpen returning true, calls to Cursor.requery were throwing Cursor already closed exceptions. I don’t know why this is but just using changeCursor worked! Additional information.

Dialog setOnClickListener not working

When making a dialog subclass I came across a problem where OnClickListener events were not firing. The solution I found here worked. It just entailed moving the onclick listener assignments from the normal Oncreate method to the onStart method.

No resource identifier found for attribute

The tag was giving messages: Multiple annotations found at this line: – error: No resource identifier found for attribute ‘backgroundColor’ in package – error: No resource identifier found for attribute ‘refreshInterval’ in package – error: No resource identifier found for attribute ‘keywords’ in package – error: No resource identifier found for attribute ‘primaryTextColor’ in package – error: No resource …

Added facebook wall posting to Android Personality Test App

I spent some time working with the facebook sdk for android. I felt like it was overkill for what I needed. So I decided to roll my own authentication handling code. When I went to post the android market had changed the publishing requirements. You now have to post two screen shots.

3rd App on the android market

Today I added my third app to the android market. The application is called Personality Test. It is a test that tells you which of the 16 personality types you are.