Simple Widget Calculator

Discussion in 'Mac Programming' started by Falrc, Jun 24, 2011.

  1. macrumors newbie

    Joined:
    Jun 24, 2011
    #1
    Hey all

    Okey, im playing around in DashCode/xCode as im starting to learn some programming. Java and Objective C.

    This is a simple Widget (java) that that will give the sum of the text field multiplied with 1,25.

    Got 1 problem, it returns the same value as the text field.

    Example

    InputValue: (your number)

    sum button: (press the button)

    textfeild: (sum of Inputvalue * 1,25 =)


    Thanks in advance.
     
  2. Moderator

    balamw

    Staff Member

    Joined:
    Aug 16, 2005
    Location:
    New England
  3. thread starter macrumors newbie

    Joined:
    Jun 24, 2011
    #3
    What do you want me to paste? I have only med the GUI for it. Been browsing around for where to add this code. Im pretty new to this, but hey, got to start somewhere.
     
  4. macrumors 603

    Joined:
    Aug 9, 2009
    #4
    I will bet you're using JavaScript, not Java. The two languages are completely different things. Java is to JavaScript, as ham is to hamster or pot is to potato.


    If there's no code, then what tutorial or book are you working from, and exactly where are you in the tutorial or book?
     

Share This Page