File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes help me to fix it Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "help me to fix it" Watch "help me to fix it" New topic

help me to fix it

Navinthran Govindasamy

Joined: Oct 29, 2012
Posts: 1
Jeff Verdegan

Joined: Jan 03, 2004
Posts: 6109

Hi, and welcome to the Ranch!

There are a number of things you can do that will make it easier and more pleasant for people to help you, which in turn will mae your experience here more productive and rewarding.

1. UseCodeTags(←click) when posting code, so that it will be readable. I've added them to your first post for you.

2. TellTheDetails(←click) about what you're having trouble with. Just throwing up a wad of code and saying "Help" puts the burden on us to figure out what kind of problem you're having, when it really should be on you to explain it.

3. Attack your assignment in small pieces, and don't move on to the next piece until you get that piece working. Then, when you have a problem, you can post just enough code to show what's relevant for the problem you're having with the small piece you're working on at the time. People aren't going to want to read that HUGE wall of code you posted.

Looking forward to hearing back from you!
Kemal Sokolovic

Joined: Jun 19, 2010
Posts: 825

Even though there is no actual question for this code, you should first check the error messages when you try to compile it. They tell you what's wrong with the code in the first place (undefined variable CustName that you try to use, and type mismatch on RoomNo).

I also must notice that your code looks more like it's written for C/C++ class then for Java class. Even those comments remind me of that.

The quieter you are, the more you are able to hear.
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 46367
Welcome again

Something else about the comments. You wrote called by. There is no such concept as a method being called by anything. A method is available to be called from anywhere, and it has no record or concept of what calls it.
The main method may call the menu method, and knows about it, but the menu method does not know what has called it.
I agree. Here's the link:
subject: help me to fix it
It's not a secret anymore!