Vadim Melders wrote:... here is my menu class, problem that I am facing here is : ... 2) print method does not work for me. Error: method print String is not applicable for the argument.
All things are lawful, but not all things are profitable.
here is my menu class, problem that I am facing here is : 1) I am not sure how can I correctly make a submenu
All things are lawful, but not all things are profitable.
Vadim Melders wrote:Forgot to mention: I can not add new item to arrayList, seems that nothing is working because of this submenu, previously with single menu everything was working
All things are lawful, but not all things are profitable.
Knute Snortum wrote:
I line 38, you are declaring the gpus object in the submenu. As soon as you return from the submenu, gpus goes out of scope. Try making gpus an instance variable by declaring it at the top of the class outside of any methods.
Knute Snortum wrote:Could you describe in detail what is going wrong?
I wasnt sure if it is correct way of making submenu by just calling a class from option menu.
...problem is when submenu case breaks menu jumps to main switch case menu options, how can I make it stay on the same menu until I press back to jump to main one.
All things are lawful, but not all things are profitable.
- from what I found about field - A Field provides information about, and dynamic access to, a single field of a class or an interface. The reflected field may be a class (static) field or an instance field. But no idea how I put it to the code.Add a "key" field to your Gcard class
Consider Paul's rocket mass heater. |