aspose file tools*
The moose likes Beginning Java and the fly likes Writing an application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Writing an application" Watch "Writing an application" New topic
Author

Writing an application

harry wykman
Greenhorn

Joined: Jul 19, 2001
Posts: 2
This semester in my university course (Object Oriented Programming at the University of Western Australia) our project was to make a component that was potentially saleable. My group made a component that took an xml file outlining a question database and returned an array of questions sorted according to a specification. That was easy.
Now, I want to make this component into an application. While I have a knowledge of many of the concepts that surround java my coding experience is dismal. I need help in turning this (for my personal use - you're not doing my homework) into a vocabulary testing program that I can use for my Latin unit. I want to be able to feed in the Latin via XML and then be tested upon those words randomly. My component takes care of that up to the point of an array of question objects correnponding to each word.
I have no idea where to begin with writing a gui and how an application is designed. Please, if you could halp me I would be most appreciative.
Harry Wykman
Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
Wow thats quite a broad request you have.
First to create an application all you need is a class that has a main() method with the following signature:

The String args[] allows you to take input as parameters when you start the app at the command line with:
>java LatinStuff firstParamter another etc
or just
>java LatinStuff
Next to get a gui started in an app you probably want to create a Frame, add some components to it, give it a size and make it visible:

Of course eventually you will need things like listeners to close the gui, and classes to actually make stuff work, but this is the shell of an app.
This what you wanted?


"JavaRanch, where the deer and the Certified play" - David O'Meara
harry wykman
Greenhorn

Joined: Jul 19, 2001
Posts: 2
That's good, thanks. The functionalitys that I want the gui to have are: displaying a question (vocab word - I think I can do this), taking an imput from a text field of some kind (I don't know how to do this) and checking it against the questions 'correct' field.
Harry Wykman.
Junilu Lacar
Bartender

Joined: Feb 26, 2001
Posts: 4456
    
    6

Harry,
One good resource for learning how to make a GUI for your application is the Java Tutorial. They have a track that teaches you all the basics: Layout managers, event listeners, frames, etc. I suggest that you go through those on your own first and come back here if you have any specific questions.
Good luck


Junilu - [How to Ask Questions] [How to Answer Questions]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Writing an application