I spent 3 days last week on a course at DevTrain, the company I'm going to start doing training for. This was the Web Apps with C# course, aimed at beginners. Now I'm not a beginner but I am going to train this course, so I sat in to see how the current trainer (and author of the course - they are all custom written) did it. It was an interesting time, as I was worried I might be bored. After all the material isn't new to me, and I used to be a trainer years ago - an MCT training VB, SQL, Exchange, NT, etc. It's always interesting to see other presenters. I see plenty at conferences but very few on courses. Actually none on courses, since I don't go on courses. But, you learn things about presenting just from watching others.
I wasn't the least bit bored. Now Steve didn't have an outlandish style, just fairly normal presenting with enough anecdotes to keep us entertained. Careful explanation plus real world examples. I found myself concentrating quite hard and enjoying it much more than I thought I would.
I learned two things.
- The first was something that VS.NET could do which I didn't know about; automatically inserting a connection strings (from a SqlConnector) into the appSettings in config.
- There's always something in the framework you don't know. A simple example was the ListBox where we were selecting an item in one listbox and clicking a button to move the item to another listbox. The first thing was to check the selected index. The next part of the example was to convert the first listbox into multi select and have the button move all selected items. I naturally dove in with a loop, but you can't change a collection while enumerating over it. Hmm, more thought required. The simple solution is just to change the if statement to a while. So from:
if (lb.SelectedIndex >= 0)
while (lb.SelectedIndex >= 0)
The point was to illustrate how you need to know the BCL. I had to admit to the students that I hadn't spotted that trick.