// Load dataset to datagridview public void LoadDataHall() { // Fetch dataset DataSet hallDS = DBGetData.GetFloorplanDGVHall(); if (hallDS != null) { // No tables fetched if (hallDS.Tables.Count == 0) { new StatusMessage("No datatable found, contact administrator."); return; } // No rows fetched else if (hallDS.Tables[0].Rows.Count == 0) { new StatusMessage("No datarows found in hall."); return; } // Clear labelStatus for previous messages else { new StatusMessage(""); } // Set the dataset as source for datagridview and make sure its displayed dataGridViewFloorplanHall.DataSource = hallDS; dataGridViewFloorplanHall.DataMember = "Get_Floorplan_Hall"; LoadDataGridViewHall(); } }