Using cm As New OleDbCommand("SELECT count(rotba) FROM Embo2018 where rotba='جندي'", Conn)
If Conn.State = ConnectionState.Closed Then Conn.Open()
TextBox4.Text = cm.ExecuteScalar
If Conn.State = ConnectionState.Open Then Conn.Close()
End Using
Using cm As New OleDbCommand("SELECT count(rotba) FROM Embo2018 where rotba='جندي أول'", Conn)
If Conn.State = ConnectionState.Closed Then Conn.Open()
TextBox5.Text = cm.ExecuteScalar
If Conn.State = ConnectionState.Open Then Conn.Close()
End Using
Using cm As New OleDbCommand("SELECT count(rotba) FROM Embo2018 where rotba='عريف'", Conn)
If Conn.State = ConnectionState.Closed Then Conn.Open()
TextBox6.Text = cm.ExecuteScalar
If Conn.State = ConnectionState.Open Then Conn.Close()
End Using
TextBox7.Text = Val(TextBox4.Text) + Val(TextBox5.Text) + Val(TextBox6.Text)