Android programming

Java — posts in this category.

Android programming

ViewPagerIndicator(2)-Fragment

I started to use ViewPagerIndicator for a few weeks. I found out each "page" inside ViewPagerIndicator is a Fragment. If that is a simple page, it will extend…

Read more
Android programming

onListItemClick is not working

You need to build a sub-class of ListActivity. Then you can override onListItemClick to catch the event on click when the list item is clicked. But that is not…

Read more
Android programming

Resource Not Found in Android

I have tried to get a string resource via getResources().getString(R.string.msg_err). Under values/strings.xml. I am 100% sure there is msg_err value. But I…

Read more
Android programming

Convert DhcpInfo.dns into a readable IP

DhcpInfo.dns1 and DhcpInfo.dns2 is an integer, not a readable IP string,"x.x.x.x". That is hard to understand. I did a search in internet. There are a number of…

Read more
Android programming

Android - On Screen Notification

In the C# Wolrd, we always use "MessageBox.Show (String)" to generate on screen notification (Pop-Up Message Box). In the Android, it has a similar thing calls…

Read more
Android programming

Android 4.0

Apple has announced iPhone 4S and iOS 5 update. I need Google to response this news too! Last week, they has announced Galaxy Nexus and Android 4.0. That is the…

Read more
Android programming

My first android program

I have written a tiny game in Android. That is my frist android progam. The game is very simple to guess what number the computer picked. But it shows how to…

Read more
Android programming

Get the instance of control

That is easy. You need to put the findViewbyId in OnCreate; txtNumber = (EditText) findViewById(R.id.txtNumber);

Read more