Hi,
I am trying to count the rows of a List -DataRow.
My initial search came up blank, so I decided to convert the DataRow into a DataTable, then perform a ‘dt.Rows.Count.ToString’, which worked great, except for when the list was blank.
Could someone explain how to perform either of these please (to resolve my issue):
- How to perform Bollean, is ‘List -DataRow’ blank
- How to count rows in a ‘List -DataRow’
- How to convert a ‘List -DataRow’ to a DataTable, even if the List is blank
I need this, as I have an IF statement which says if it is NULL, then do A, else do B.