• Post Reply Bookmark Topic Watch Topic
  • New Topic

Getting IOException

 
Leong Kah Soon
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys, can someone take a look at my code and look at what's the problem with my code? The main part of this question is this:

1. I set my customerID to user input on my MainMenu class which then calls other classes's setCustomerID to set to the user input as well.
2. If you ran the file, you'll notice that first time you'll be prompt to enter user id and all that, and all those data entered will be recorded to a txt file on your C:\\RetailDatabase\\
3. After you created a customer entry file / you search an existing one, you'll then be prompt to create a enquiry / order or return statement.

Here comes the problem:

4. If I wanted to create enquiry, it works fine. But when I wanted to create order, it gives me the IOException which I declared.

It wasn't suppose to be like that, I mean four of the addCustomer / addEnquiry / addOrder / addReturn coded in the same way. But only the enquiry worked while the order doesn't thus it creates an empty null folder on C:\\RetailDatabase\\Order\\ which was supposingly to be the entered customerID which
I set during MainMenu.

Anybody have any idea why?

Here's the link to my file: http://www.mediafire.com/?macymlqpear3bf5

*NOTE*: The reason why I don't to copy the necessary code is because it's too long that it would be easier if you just download an open up the file.
 
Tony Docherty
Saloon Keeper
Posts: 3142
72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch.

Many people won't download files so I suggest you post an SSCCE or at the very least the section of code that is throwing the exception.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!