When using scrapbook:
ArrayList<Book> list = new ArrayList<Book>();
Book b1 = new Book("Great Expectations");
Book b2 = new Book("War and Peace");
list.add(b1);
list.add(b2);
Person p1 = newPerson();
p1.setName("Fred");
b1.setPerson(p1);
list
I get the "Cannot use this in a static context" error message. Anny ideas?
btw: This tutorial is beyond excellent! It is good to follow the presentation, rewind, and do it.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When using scrapbook:
ArrayList<Book> list = new ArrayList<Book>();
Book b1 = new Book("Great Expectations");
Book b2 = new Book("War and Peace");
list.add(b1);
list.add(b2);
Person p1 = newPerson();
p1.setName("Fred");
b1.setPerson(p1);
list
I get the "Cannot use this in a static context" error message. Anny ideas?
btw: This tutorial is beyond excellent! It is good to follow the presentation, rewind, and do it.
I found the error. It was a student malfunction. I put newPerson as one word instead of new Person.