wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes printing message Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "printing message" Watch "printing message" New topic
Author

printing message

jonathan cassar
Greenhorn

Joined: Jan 17, 2010
Posts: 4
I'm trying to do the following using java language.

The user is to enter some item description. (item code, item weight, item unit price). When the user has finished, he is to enter an item code and the system must retrive the contents of the code if it was entered before. i managed to do all this stuff however I'm finding some problems regarding the user entering a code which is not found in the system.

As shown in the code here under I'm using an array list to store my objects in it. When I'm iterating through the array list and getting the information back, to display the code I'm getting funny results. When the user enters a code which is found in the system,the program is still outputing that no such code exists. Is there a way to by pass this problem please

Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60810
    
  65

Please avoid posting in all uppercase. Please read this for more information.

I have adjusted the title for you.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
jonathan cassar
Greenhorn

Joined: Jan 17, 2010
Posts: 4
Thanks for the correction
 
wood burning stoves
 
subject: printing message
 
Similar Threads
output prints null
NullPointerException
OVERWRITING OBJECTS IN AN ARRAY LIST HELP PLEASE
Currency Problem + General Advice
Need help with set and get using a scanner input with three different classes