To expand on what Knute said: Remember that there is one instance of each static member of a class, irrespective of how many instances there are. So there is one main method, whether there are 1, 2, 3, 1,000,000,000 instances . . . or even no instances at all. If you are in the main method, how are you to know which copy of an instance member you want? What if there aren't any instances yet, and there aren't any instance fields in existence yet? There is no way to verify that sort of thing, so it won't compile. You get what I think is a confusing error message about things non‑static, but I think the correct solution is to move as much of that code as possible out of the main method.
martin andreas wrote:. . . for what reason can't you use instance variables straight from main? . . .
Yes, but the idea of object‑oriented programming is to have as much as possible of the code relating to objects. I don't like adding the keyword static if it is possible to change things from static to “instance”? Do you mean, “instance method,” by, “reference method”.
Julius Adek wrote:. . . However, if this locationCell has been created as static variable; you would have been able to call locationCell within any static or reference method especially the main method.
You mean that static members have an existence as soon as the class is loaded.
All static members of a class are always globally accessible.