I use this code to get pending windows updates and also most of the informations of the update:
static List GetPendingUpdates() {