Controls Binding Inquiry?

  • Thread starter Thread starter al
  • Start date Start date
A

al

Hi,

If controls (textboxs,combos,etc...) are dataset-bound and dataset is
used interchangeably (rowfilter on and off), do I have to clear
bindings when user get different no. of records, or binding context
will adjust itself to this?? That is, do I have to call this sub each
time row filter is changed (on and off)


Sub clearbinding()
Dim ctl As Control
Dim txt As Control


ds.Tables("employees").clear
For Each ctl In frmemp.Controls
If TypeOf ctl Is GroupBox Then
For Each txt In ctl.Controls
If TypeOf txt Is TextBox Then
txt.Text = ""
txt.DataBindings.Clear()
End If
Next
End If
Next
ds_changexposition()
End Sub
MTIA,
Grawsha
 
Hi al,

al said:
Hi,

If controls (textboxs,combos,etc...) are dataset-bound and dataset is
used interchangeably (rowfilter on and off), do I have to clear
bindings when user get different no. of records, or binding context
will adjust itself to this?? That is, do I have to call this sub each
time row filter is changed (on and off)

I don't think it is necessary at all.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top