Android Development

As mentioned in a previous post I’ve been trying my hand at Android development.

I was working on a simple shopping list app, the idea being you’d be able to create one or more lists that contain items you needed to buy, or do. For example a list called “Shopping” that with all the groceries you needed to buy! Lists and items could be deleted and the items had a check box for you to toggle when you’ve bought the item.

Here’s a screenshot of it in action;

A screenshot of ShopMe in action!
A screenshot of ShopMe in action!

If you’re interested the source code is available here but don’t expect a great deal, it was a learning project after all! If you’re knowledgeable about Android development, please leave a comment, I’d be interested to know if there’s anything I’ve done wrong!

While it was enjoyable tinkering with Android, I have to say there were a few tricky problems which I found tricky because the answers weren’t immediately apparent. Here they are below;

Creating a custom list view

I wanted to use a custom list view for the shopping list because I also wanted the list items to contain buttons, for example the check box and the delete button. It became clear quite quickly that I wouldn’t be able to use the standard view, thankfully though I found this which put me on the right path.

Using a database

Not a particularly demanding request, being able to save your lists! The tutorials here were very useful so I was able to get this working pretty quickly.

Testing 

As part of my Android learning I wanted to try writing a test to validate that my app was working as expected. I struggled a bit getting this to work with normal unit tests but I found Robotium, which simplified things quite a bit.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s