satyamurthy

Discussion in 'Introductions' started by satyamurthy_hyd, Jul 28, 2010.

  1. satyamurthy_hyd

    satyamurthy_hyd New Member
    15

    Jul 28, 2010
    4
    0
    15
    Hi,
    I have Hexadecimal value and need to assign to a button's background by setBackgroundColor(),but getting Runtime Exception: see the code snippet below with exception output. Please help me resolve this

    String strColor="0xFFF3ECE0";
    int intColor= Integer.parseInt(strColor,16);
    button1.setBackgroundColor(intColor);

    ERROR/AndroidRuntime(874): java.lang.NumberFormatException: unable to parse '0xFFF3ECE0' as integer
     

    Advertisement
  2. satyamurthy_hyd

    satyamurthy_hyd New Member
    15

    Jul 28, 2010
    4
    0
    15
    Do we have any Data bind UI controls in Android?
     
  3. Steven58

    Steven58 Reformed PH
    VIP Member
    3,823

    Feb 19, 2010
    32,921
    25,271
    3,823
    Male
    Welcome to Android Forums! :)
     
  4. G.Armour

    G.Armour You know you want to.
    VIP Member
    173

    Jan 11, 2010
    4,534
    306
    173
    Truck driver/ driver mentor. I train people to dri
    Georgia
    Wow. Welcome!
     

Share This Page

Loading...