Hi there,
I'm desperetely trying to create a method which would delete all rows (which i add through another), but it doesn't seem to work:
Init Paths Method:
and above (for now only the last row, but i can hopefully get it thorugh a Loop later)is my remove Paths Method (that doesn't work) what i want to accomplish is be able to clear all rows,
I'm desperetely trying to create a method which would delete all rows (which i add through another), but it doesn't seem to work:
Init Paths Method:
private void InitPaths() { int c = 1; int a = 1; while (a < pathRows.Length-1) { var label = new Label(); // // Label - Format. // label.Dock = DockStyle.Fill; label.AutoSize = false; label.Text = pfadZeilen[a]; label.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; label.Size = new System.Drawing.Size(22, 13); label.BackColor = System.Drawing.Color.Transparent; _LayoutTable.Controls.Add(label, 3, c); a++; c++; } }
private void ClearPaths() { BibTable.RowStyles.RemoveAt(BibTable.RowStyles.Count - 1); }
and above (for now only the last row, but i can hopefully get it thorugh a Loop later)is my remove Paths Method (that doesn't work) what i want to accomplish is be able to clear all rows,
after they are inserted.