The example demonstrates how to support sorting through column headers for the DataGridView.
Download the file by clicking the link above.