c# - How to count bytes of data stored inside a DataTable -
assume have datagridview bound datatable. there simple yet realiable way determine total size of stored data (in bytes) inside datatable?
if want number of cells, can multiplying columns rows:
int cells = tbl.columns.count * tbl.rows.count;
if want size in bytes, try serializing datatable , measuring size, won't 100% accurate, since add boilerplate.
Comments
Post a Comment