Search:

Type: Posts; User: EDale

Search: Search took 0.08 seconds.

  1. Re: Error message non-static method Person.getFirstName() cannot be referenced from a static context?

    I got it. Thank you so much! This was my last programming assignment of the semester. So glad it's over!
  2. Re: Error message non-static method Person.getFirstName() cannot be referenced from a static context?

    So are you saying I should create a person object within my Person class to be able to call methods from that class?
    Like:


    Person p = new Person("Joe", "Smith", "0394857");


    To call...
  3. Re: Error message non-static method Person.getFirstName() cannot be referenced from a static context?

    I'm talking about changing the getFirstName() method to static not the toString() method. I cant call the toString() because I can't even compile the student class.
  4. Error message non-static method Person.getFirstName() cannot be referenced from a static context?

    Hi, I have a super class Person and its sub class Student. Student has a toString method that prints out the details of the Student object including the first name. But I keep getting the error...
Results 1 to 4 of 4