Results 1 to 3 of 3

Thread: help with this ?

  1. #1

    Thread Starter
    Member alistair4267's Avatar
    Join Date
    Jul 2001
    Posts
    45

    help with this ?

    hi

    i need help with this calculator i am working on in java. i don't understand why it isn't working

    C:\Documents and Settings\Kole\My Documents\Programming\Java\Calculator\Assignment\Kalkulator.java:409: double cannot be dereferenced
    sX = dX.toString();
    ^
    1 error
    Exit code: 1
    There were errors


    Attached Files Attached Files

  2. #2
    Hyperactive Member
    Join Date
    Jun 2002
    Location
    Tulsa,Ok
    Posts
    262
    I am just learning java so I amy have this wrong but I pretty sure this code

    Code:
    sX = dX.toString();
    should read

    Code:
    sX = String.ValueOf(dX).toString();
    I got the same error you did so I change the above line of code to wrap the String class.

    Hope that helps,

    Jerel

  3. #3

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width