The form gets slower to load and also save as more records are added to database:
Is there another way i can avoid loading the database table first?
Is there another way i can avoid loading the database table first?
VB.NET:
If State = gModule.FormState.adStateAddMode Then
Try
Dim qryCompanies As String = "SELECT * FROM `tbl_business`"
daCompanies.SelectCommand = New MySqlCommand(qryCompanies, conn)
Dim cb As MySqlCommandBuilder = New MySqlCommandBuilder(daCompanies)
daCompanies.Fill(dsCompanies, "tbl_business")
Me.txtAppFormNo.Focus()
Catch ex As MySqlException
MsgBox(ex.ToString)
Finally
conn.Close()
End Try
ElseIf State = gModule.FormState.adStateEditMode Then