Initialize page (session ping + control reset)¶
Every page that inherits AppViewPageBase runs this operation on the standard ASP.NET Init/Load lifecycle. It enables session keep-alive by default (unless the client is external) and normalizes control back-color styling so form fields render consistently across postbacks.
| Field | Value |
|---|---|
| Operation ID | OP-CORE-001 |
| Trigger | ASP.NET page lifecycle Init and Load events |
| Inputs | EnableSessionPing, CallResetBackcolor, environment client classification |
| Outputs | Registered client script blocks; CSS classes reset on every control in the page tree |
| Primary components | AppViewPageBase.Page_Init, AppViewPageBase.Page_Load, AppViewPageBase.CallSessionPing |
| Entry point | SAIF.Presentation.Web.Core.Infragistics111/AppViewPageBase.aspx.vb |
Steps¶
- On
Init, setEnableSessionPing = Trueand call the designerInitializeComponent. (BR-CORE-001) - On
Load, callCallSessionPing(). - In
CallSessionPing, ifEnableSessionPingisFalse, exit immediately without registering any script. - Query
AppGlobal.EnvironmentService.IsClientExternal. (BR-CORE-002) - If the client is external: skip script registration entirely and return.
-
Origin: This step delegates to
AppGlobal.EnvironmentService.IsClientExternal, provided by the SAIF framework environment service (packageSAIF.BOF.Framework). The callee's internal classification logic is not implemented in this repository and could not be traced.** - Build a script include for
/resources/scripts/PingSession.jsand a startup script callingInitializeSessionPing(). - If the
SessionPingscript block is already registered on the page: skip registration (no duplicate). (BR-CORE-003) - Otherwise: register both script blocks via
ClientScript. - Back in
Load, evaluateCallResetBackcolor. - If
True: callUtilities.clsControlManager.ResetBackColor(Me). (BR-CORE-004) > Origin: Step 6's back-color normalization is fully implemented in Reset control back colors (SAIF.Presentation.Web.Core.Infragistics111, this library) — see that page for the recursive control-tree logic. - If
False: no back-color reset occurs this cycle.
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
Start([Page Init/Load]) --> S1["Page_Init: EnableSessionPing = True"]
S1 --> S2[Page_Load: CallSessionPing]
S2 --> D1{EnableSessionPing?}
D1 -->|No| EndSkip([No script registered])
D1 -->|Yes| D2{IsClientExternal?}
D2 -->|Yes| EndSkip
D2 -->|No| D3{SessionPing already registered?}
D3 -->|Yes| EndOk([Ping active])
D3 -->|No| S3[Register PingSession.js + startup script]
S3 --> EndOk
S2 --> D4{CallResetBackcolor?}
D4 -->|Yes| S4[ResetBackColor recurses page tree]
D4 -->|No| EndNoReset([Colors unchanged])
S4 --> EndOk
Failure and edge-case behavior¶
- If
AppGlobal.EnvironmentServiceis unavailable, the client-classification query would fail; this library assumes the environment service is always present at runtime.** - Repeated
Loadevents (e.g. partial postbacks) never duplicate the ping script because of the registered-block check in step 5.
Related documentation¶
Sources¶
SAIF.Presentation.Web.Core.Infragistics111/AppViewPageBase.aspx.vb