[Java for Android App Development] Sahaab:
i use the exact same code you gave, and i just keep getting an overflow logcat for the ImageButton

i have tried making various changes, but still same thing :-/

it gets fixed inside eclipse, but still doesnt work on my phone :-/

Edit: Log

06-18 18:04:28.595: E/AndroidRuntime(1138): FATAL EXCEPTION: main
06-18 18:04:28.595: E/AndroidRuntime(1138): Process: com.ashutos.quantumpaperui, PID: 1138
06-18 18:04:28.595: E/AndroidRuntime(1138): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ashutos.quantumpaperui/com.ashutos.quantumpaperui.MyActivity}: android.view.InflateException: Binary XML file line #24: Error inflating class android.widget.ImageButton
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2195)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread.access$800(ActivityThread.java:135)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.os.Handler.dispatchMessage(Handler.java:102)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.os.Looper.loop(Looper.java:136)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread.main(ActivityThread.java:5017)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at java.lang.reflect.Method.invokeNative(Native Method)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at java.lang.reflect.Method.invoke(Method.java:515)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at dalvik.system.NativeStart.main(Native Method)
06-18 18:04:28.595: E/AndroidRuntime(1138): Caused by: android.view.InflateException: Binary XML file line #24: Error inflating class android.widget.ImageButton
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.createView(LayoutInflater.java:620)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at com.android.internal.policy.impl.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:56)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.onCreateView(LayoutInflater.java:669)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:694)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:290)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.Activity.setContentView(Activity.java:1929)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at com.ashutos.quantumpaperui.MyActivity.onCreate(MyActivity.java:14)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.Activity.performCreate(Activity.java:5231)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2159)
06-18 18:04:28.595: E/AndroidRuntime(1138):	... 11 more
06-18 18:04:28.595: E/AndroidRuntime(1138): Caused by: java.lang.reflect.InvocationTargetException
06-18 18:04:28.595: E/AndroidRuntime(1138):	at java.lang.reflect.Constructor.constructNative(Native Method)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.view.LayoutInflater.createView(LayoutInflater.java:594)
06-18 18:04:28.595: E/AndroidRuntime(1138):	... 27 more
06-18 18:04:28.595: E/AndroidRuntime(1138): Caused by: java.lang.StackOverflowError
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.DrawableContainer$DrawableContainerState.<init>(DrawableContainer.java:511)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.StateListDrawable$StateListState.<init>(StateListDrawable.java:281)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.StateListDrawable.<init>(StateListDrawable.java:327)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.StateListDrawable.<init>(StateListDrawable.java:75)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:898)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXml(Drawable.java:877)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.content.res.Resources.loadDrawable(Resources.java:2092)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.content.res.Resources.getDrawable(Resources.java:700)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.StateListDrawable.inflate(StateListDrawable.java:176)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:937)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXml(Drawable.java:877)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.content.res.Resources.loadDrawable(Resources.java:2092)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.content.res.Resources.getDrawable(Resources.java:700)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.StateListDrawable.inflate(StateListDrawable.java:176)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:937)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.graphics.drawable.Drawable.createFromXml(Drawable.java:877)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.content.res.Resources.loadDrawable(Resources.java:2092)
06-18 18:04:28.595: E/AndroidRuntime(1138):	at android.cont

Edit 2 : working just fine without button

Edit 3: Figured it out