Hint: The ListView control’s Items property is a collection of ListViewItem objects. Loop
through that collection to get information about each row.
Hint: Each
ListViewItem has a SubItems property that is
a collection of
ListViewItem.ListViewSubItem objects.
For each row, loop through the item’s subitem collection
to get the values for that row. Use
Console.Write to add
data to the
Console window without adding a carriage
return.
5. Make a program similar to the one shown in Figure 19-3
that generates all possible four-letter words using the let-
ters A, B, C, and D. (Hint: Make an array containing the
letters A, B, C, and D. Use a
foreach loop to loop through
the letters. Inside that loop, use another loop to loop
through the letters again. After four depths of nested loops,
concatenate the looping variables to get the word.)
You can download the solutions to these exercises from the book’s web page at
www.wrox.com or www.CSharpHelper.com/24hour.html. You can find them in
the Lesson19 folder.
FIGURE 193
596906c19.indd 239 4/7/10 12:33:25 PM
Click here to Play