There are basically 2 ways to do this:
1. use the ADO.NET DataSet object, which tracks all inserts and updates to
its in-memory representation. The SqlDataAdapter lets you setup sql commands
that will execute for insert, update and delete. Then you call
SqlDataAdapter.Update and pass in an array of DataRows. There are
variations on this theme that would be covered by any decent ADO.NET book.
2. build the big sql string yourself using StringBuilder. This option
performs better, since only a single batch is submitted to the sql server.
If you need good performance, and know transact sql, just concatenate the
inserts/updates, connect, and execute the entire batch at once. You can
actually walk the DataSet also to generate this sql. This technique may not
be in too many tutorials.