Skip to content

Grid/DDL live data-source update

This operation finds the existing binder registered for a grid or dropdown control and updates its data source, then immediately refreshes the control's displayed contents.

Field Value
Operation ID OP-BIND-007
Trigger Explicit call to clsObjectBindManager.Update(UltraWebGrid|WebDataGrid|DropDownList, dataSource), e.g., after a filter or reload changes the underlying collection
Inputs The control instance; its new IEnumerable/data source
Outputs The matching existing binder's BindSource is updated and ObjectToControl() is re-invoked
Primary components clsObjectBindManager.Update, clsObjectBindManager.AddBinder, clsObjectBinderBase.ObjectToControl
Entry point SAIF.Presentation.Web.Binding.Infragistics103\clsObjectBindManager.vb

Steps

  1. Scan m_Bindings for an existing binder of the matching concrete type (clsUltraGridBinder, clsWebDataGridBinder, or clsDDLBinder) whose FormControlID matches the passed control's UniqueID and whose BindType is ObjectToControl or TwoWay.
  2. If found, set the binder's BindSource to the new data source.
  3. Re-register the binder via AddBinder().
    • On this path: AddBinder() appends a new entry to m_Bindings rather than replacing the existing one — a potential duplicate-binder side effect, observed from reading the method body but not confirmed as intentional design.*
  4. Call Binder.ObjectToControl() immediately to refresh the control (see Object to control data push).

Process flow

The following diagram visualizes this operation's control flow.

flowchart TD
    Start([Update called]) --> Scan[Scan m_Bindings for matching control UniqueID and BindType]
    Scan --> Found{Matching binder found?}
    Found -->|No| EndNoop([No action taken])
    Found -->|Yes| SetSource[Set binder BindSource to new data source]
    SetSource --> ReAdd[Re-register via AddBinder appends new entry]
    ReAdd --> Refresh[Call ObjectToControl to refresh control]
    Refresh --> EndOk([Control refreshed with new data])

Failure and edge-case behavior

  • If no binder matches the control's UniqueID/BindType, the call is a no-op — no error is raised.*
  • Repeated calls to Update() for the same control accumulate duplicate binder entries in m_Bindings because AddBinder() always appends; this is a latent risk rather than a confirmed intentional design choice.*

Sources

  • SAIF.Presentation.Web.Binding.Infragistics103\clsObjectBindManager.vb