CS 230 Spring 2007                          Assignment 10 – More Files–                                                          100 points

 

Assigned: 04/04/2007

Due: 04/18/2007 at the start of class

 

Pre-Lab (Do Before Lab):  Bring materials – a way to save a copy for you and a copy to turn in. Plan out tasks, objects, and events needed for program. Write pseudocode for the main buttons and for functions / independent sub procedures.

.

Main Assignment:

LaSoogle Labs is developing an online radio station in which you create your own personal radio station and music is streamed to you based on what you like and don’t like (like other services already out there).  Your program is a simplification dealing with ranking songs (only). .

·         The program should get from a file (songs.txt) a list of songs and display them in a list box.

·         When the user selects a song from the song list box, the song information should be displayed in two read-only text boxes or in labels.  Separate the song title and artist (the file format is to divide these using the word “by” instead of a comma.)

·         When a user specifies a rating (0-5) AND selects a “Rate” button, write the rating (song, artist and rating) to a comma-delimited text file for later tabulation (add it to those already in the file), and remove the song from the list box of songs. (DO NOT have the rating recorded immediately upon selection in case of inadvertent click).

·         Provide the rate capability, a clear (clear song and artist, set rating to default, and clear any selection in the list box (see below)),  and an exit capability.

·         A sample interface is provided on page 2. Don’t let that constrain your creativity. Use it to help understand what I see as the inputs and outputs.

Hand in:

Task Details:

·         It is permissible (recommended) to use a combo box to obtain the user’s rating of a song.  You can avoid the need to validate rating at all if you:

1.        use a DropDownStyle property value of DropDownList – which makes it impossible for the user to type in values of their own, and

2.        always ensure that the combo box has a default value. When loading the form and when clearing, set cmboboxname.SelectedIndex = thenumberoftheitemyouwanttobethedefault (starts counting with zero)

·         If the rating is done as a regular text box, you must validate as always.

·         You need to ensure that a song has been selected before accepting a rating (display a msgbox complaining if not)

Miscellaneous