[Data Binding] slow ?

  • Thread starter Thread starter Agnes
  • Start date Start date
A

Agnes

I got a tables which got 10,000 records.
user will input the invoice no as key.
my strConnection = "select * from invoice_Table where invno ='" &
(Me.txtInvoiceNo.Text) &"' "
in my form, there are over 20 textbox.
If i use databinding to bind each textbox. will it become slow ???
if i move the position, will it slow ??

Thanks
 
Hi Agnes,
I got a tables which got 10,000 records.
user will input the invoice no as key.
my strConnection = "select * from invoice_Table where invno ='" &
(Me.txtInvoiceNo.Text) &"' "

Do you have invoices with 10000 rows?

By the way, you better can use a command.parameter to fill that variable in
the selectstring

Cor
 
10,000 is a lot of data, but it depends on a lot of things. I try not to
push about 5k as a rule, but I've done about 20k and not had any performance
issues on P4's all of which had 256 mb.
 
If your using a dataset (especially a typed one) use the BeginLoadData
method.

i.e.

Dim myStrongDataset1 as new myStrongDataSet1

myStrongDataset1.MyTable.BeginLoadData()
myDataAdapter.Fill(myStrongDataset.MyTable)
myStrongDataset1.myTable.EndLoadData()

this turns off notifications which can cause performance problem.s

You can also use the currency manager to assist this with

dim cm as CurrencyManager

cm = BindingContext(myStrongDataset1, "MyTable")

cm.SuspendBinding

myStrongDataset1.MyTable.BeginLoadData()
myDataAdapter.Fill(myStrongDataset.MyTable)
myStrongDataset1.myTable.EndLoadData()

cm.ResumeBinding

HTH,
CJ
 
Back
Top