The method is used to set custom error descriptions on specified columns. You can use the System.Windows.Forms.ErrorProvider control to display the text of the error.
To examine error descriptions, use the DataRow.GetColumnError(int) method.
To determine whether any errors exist for the columns collection, use the DataRow.HasErrors property. Consequently, you can use the DataRow.GetColumnsInError method to retrieve all the columns with errors.
If null or an empty string is passed in as the error parameter, the System.Data.DataRow behaves as if no error was set and the DataRow.HasErrors property will return false.
To set a custom error description on the whole row, use the DataRow.RowError property.
To clear all errors for the columns collection, use the DataRow.ClearErrors method.
To set error text that applies to a whole row, set the DataRow.RowError property.