Object to control data push¶
This operation iterates all registered binders and pushes the current value of each bound business-object property into its associated control, refreshing the displayed UI state.
| Field | Value |
|---|---|
| Operation ID | OP-BIND-002 |
| Trigger | Explicit call to DataBind(), or automatically from OnPreRender when AutoBind = True |
| Inputs | The manager's current m_Bindings list; each binder's m_BindSource |
| Outputs | Control UI state updated to reflect current business-object property values |
| Primary components | clsObjectBindManager.DataBind, clsObjectBinderBase.ObjectToControl (per concrete binder), clsObjectBinderBase.GetObjectValueAsString/GetObjectValue |
| Entry point | SAIF.Presentation.Web.Binding.Infragistics103\clsObjectBindManager.vb |
Steps¶
- Iterate
m_Bindings; for each binder whoseBindTypeisObjectToControlorTwoWay, callBinder.ObjectToControl(). - Each concrete binder's
ObjectToControl()reads the property value viaGetObjectValueAsString/GetObjectValue(reflection +TypeDescriptor/PropertyDescriptor, with optional padding applied perUsePadding/ControlPadding) and assigns it to the appropriate control property/selection (e.g.,TextBox.Text,DropDownList.Items.FindByValue, grid data source). - On failure: if the target property cannot be converted (
NotSupportedException),GetObjectValueAsStringreturnsNothingand the control is left unset; no exception propagates to the caller.* - No business-rule IDs or SQL/table references apply to this step sequence — this is pure UI projection.
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
Start([DataBind called]) --> Iterate[Iterate m_Bindings]
Iterate --> Check{BindType is ObjectToControl or TwoWay?}
Check -->|No| Next[Skip binder]
Check -->|Yes| Read[ObjectToControl: read property via reflection]
Read --> Pad{UsePadding?}
Pad -->|Yes| ApplyPad[Apply ControlPadding]
Pad -->|No| Assign[Assign value to control]
ApplyPad --> Assign
Assign --> Next
Next --> Done{More binders?}
Done -->|Yes| Iterate
Done -->|No| EndOk([Controls refreshed])
Failure and edge-case behavior¶
- A property value that fails conversion leaves the target control unchanged rather than raising an exception to the page.*
Related documentation¶
Sources¶
SAIF.Presentation.Web.Binding.Infragistics103\clsObjectBindManager.vbSAIF.Presentation.Web.Binding.Infragistics103\clsObjectBinderbase.vb