Programming
How to Solve Problem (emulator: ERROR: the user data image is used by another emulator. aborting)
Posted on September 30, 2010 |
In this post i will share how to solve error “emulator: ERROR: the user data image is used by another emulator. aborting”. When we run android emulator tools via eclipse sometime we get this error. After i search all around the net there is look like no other option than do this step to solve the problem.
1. Go to where we put the emulator running configuration. in my case “c:\document and settings\<username>\.android\avd\<device>
2. delete this two directory “userdata-qemu.img” and cache.img
3. Re run your emulator via eclipse, this will launch new emulator
Hope this post will help you that have same problem with me.
Programming Android: Create Icon with Text Using GridView and Layout Inflater
Posted on February 19, 2010 |
How to create Icon With text like home screen, here is my example screen:
![]()
To do something like this we need to use GridView and make The Icon with text using the XML layout and then using LayoutInflater to read the XML and put it into the Adapter. Lets begin with the icon.xml(we put it into /res/layout/) that will be the view to show ImageView and Text together.
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/widget44" android:layout_width="wrap_content" android:layout_height="wrap_content" android:orientation="vertical" android:layout_x="201px" android:layout_y="165px" android:gravity="center_horizontal"> <ImageView android:id="@+id/icon_image" android:layout_width="wrap_content" android:layout_height="wrap_content"> </ImageView> <TextView android:id="@+id/icon_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="TextView" android:gravity="center_horizontal" android:textColorHighlight="#656565"> </TextView> </LinearLayout>


