PDA

View Full Version : cho hỏi cách làm bài lab C# này



phonghieu45
02-07-2011, 16:05
create a delegate name Check has a string parameter and return void type
Create a class name Album following:
- A private field name song has String type;
- a public field named Al_Song has Arraylist type;
- a method name Waring has a string parameter and return void type. Inn this method, print out the string is passed in parameter.
-an event name CheckEvent base on check delegate, this event subscribe to Warning method.
-a property name Song. This property accept all string except "end " or "End" string;
if the data is invalid, the event is raised with a message "please enter other string"'
else
the data is add in to ArrayList Al_song;
Create a class name Test:
This class contain a menu:
1: Add
2: View
3: Exit
The case1 : The programs asks the user enter the name song;
The case2: use foreach to display List album.