What I want is to fill DataTable
with addresses of my images, and this table will be increased according to the number of files in a folder in which I store my images, only that I get an error that I could not solve and here is my code.
Table Code:
DataTable dTable = new DataTable();
dTable.Columns.Add("Ruta");
DataRow dr = dTable.NewRow();
dr["Ruta"] = "Imagen";
dTable.Rows.Add(dr);
dataInfo.DataSource = dTable;
At the moment I should just show a table with the route column and the image value, but it marks the error of the title.
Reference to object not established as an instance of an object.
The error marks me on the following line:
dataInfo.DataSource = dTable;