943,752 Members | Top Members by Rank

Ad:
  • Java Discussion Thread
  • Unsolved
  • Views: 2156
  • Java RSS
Nov 9th, 2008
0

very basic java GUI Program...

Expand Post »
i am new to java, i am writing this program so where when the user inputs RGB values the resultant colour should be displayed on a frame. (note that you cann't use the color class in java)

1.) i have successfully completed coding for where the user inputs the RGB values and it works perfectly.

what i want to do is, how to display the colour that corresponds to this 3 RGB values ...

for example , if we input (223,70,98) as for RGB , the corresponding colour should be displayed... can your'l do me a sample code so that i could understand the scenario ..

help !!!!
Similar Threads
Reputation Points: 1
Solved Threads: 3
Junior Poster
localp is offline Offline
190 posts
since Apr 2008
Nov 9th, 2008
-1

Re: very basic java GUI Program...

Any chance of you being student at University of Westminster in your second year doing 1st coursework?
Moderator
Featured Poster
Reputation Points: 2786
Solved Threads: 871
Code tags enforcer
peter_budo is offline Offline
6,656 posts
since Dec 2004
Nov 9th, 2008
0

Re: very basic java GUI Program...

Click to Expand / Collapse  Quote originally posted by peter_budo ...
Any chance of you being student at University of Westminster in your second year doing 1st coursework?


Your right !
Reputation Points: 1
Solved Threads: 3
Junior Poster
localp is offline Offline
190 posts
since Apr 2008
Nov 9th, 2008
0

Re: very basic java GUI Program...

All what John wants is just you to re-create Color class, but call it Colour as not to clash with original class. The exercise aims for you to show your understanding the concepts of creating new classes through variety of constructors as described per assignment. With set of accessors and setters methods to manipulate values stored by this class.

Notes for teaching week 3,4 & 5 is exactly what you will need it. If you want to pop in the library Deitel's book Java How to Program (6th Ed) and chapter 3 is again useful material to look into. So apply John's notes of dice to your assignment and you will do just fine

PS: The program is not GUI, you may learn about GUIs in the Event-Driven Programming module in second semester;)
Last edited by peter_budo; Nov 9th, 2008 at 6:02 am. Reason: add PS
Moderator
Featured Poster
Reputation Points: 2786
Solved Threads: 871
Code tags enforcer
peter_budo is offline Offline
6,656 posts
since Dec 2004
Nov 9th, 2008
0

Re: very basic java GUI Program...

but is there a way that i could view the implementation of the class color . could some one please advice me on this
Reputation Points: 1
Solved Threads: 3
Junior Poster
localp is offline Offline
190 posts
since Apr 2008
Nov 9th, 2008
-1

Re: very basic java GUI Program...

Here is link to Color class in the API
Moderator
Featured Poster
Reputation Points: 2786
Solved Threads: 871
Code tags enforcer
peter_budo is offline Offline
6,656 posts
since Dec 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Java Forum Timeline: inter JVM method calls
Next Thread in Java Forum Timeline: help...want to cr8 mobile game "go"





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC