private void Categories_Load(object sender, EventArgs e) { resetText(); CategoryID.Focus(); dataGridView1.DataSource = tl.getList(); CategoryID.Text = dataGridView1.Rows.Count.ToString("00"); dataGridView1.AutoResizeColumns(); }