---
title: AppViewMasterPageBase
summary: API reference for AppViewMasterPageBase.
status: draft
owner: SAIF Doc Gen
last_reviewed: 2026-08-17
library: SAIF.Presentation.Web.Core.Infragistics111
reference_type: package
---

# AppViewMasterPageBase

`AppViewMasterPageBase` is the master-page base class shared by every SAIF application chrome layout in this package. It provides typed accessors for the standard chrome controls (script manager, banner, menu, message/error labels, claim/policy headers, main `UpdatePanel`) so consuming master pages do not need to `FindControl` for them, and it owns the client-side focus mechanism that targets the correct DOM selector for whichever Infragistics or standard control type currently holds `FocusControl`.

## Purpose
- Provide typed, discoverable access to the standard SAIF chrome controls instead of requiring each consuming master page to re-declare `FindControl` calls.
- Determine, on `PreRender`, whether a `FocusControl` was set and — if so — emit a client script that focuses it using a selector appropriate to its runtime control type. ([BR-CORE-028](../../business-rules.md#br-core-028-no-focus-script-is-emitted-when-the-master-page-has-no-focus-control), [BR-CORE-029](../../business-rules.md#br-core-029-client-side-focus-targeting-is-control-type-specific-because-infragistics-editors-render-nested-input-elements))
- Wrap the focus call in a defensive `try/setTimeout/catch` so a missing DOM element never breaks page rendering. ([BR-CORE-030](../../business-rules.md#br-core-030-focus-is-applied-100-ms-after-load-inside-a-trycatch-so-a-missing-element-never-breaks-the-page))

## Context
- Namespace: `SAIF.Presentation.Web.Core`
- Assembly/package: `SAIF.Presentation.Web.Core.Infragistics111` (merged into `SAIF.Presentation.Web.Infragistics111.dll` via `SAIF.BOF.Presentation.Web.Infragistics111.nuspec`)

## Public members
| Member | Signature | Purpose |
| --- | --- | --- |
| `FocusControl` | `Public Property FocusControl As Control` | The control that should receive client-side focus after the current page render; `Nothing` when no focus target is set. |
| `ScriptManager1` | `Public ReadOnly Property ScriptManager1 As ScriptManager` | Typed accessor for the master page's `ScriptManager` chrome control. |
| `Banner` | `Public ReadOnly Property Banner As BannerControl` | Typed accessor for the standard SAIF banner chrome control. |
| `Menu` | `Public ReadOnly Property Menu As SAIFMenu` | Typed accessor for the standard SAIF left/side navigation menu control. |
| `MenuTop` | `Public ReadOnly Property MenuTop As SAIFMenuTop` | Typed accessor for the standard SAIF top navigation menu control. |
| `MessageLabel` | `Public ReadOnly Property MessageLabel As SAIFMessage` | Typed accessor for the standard informational message display control. |
| `ErrorLabel` | `Public ReadOnly Property ErrorLabel As SAIFMessage` | Typed accessor for the standard error message display control. |
| `MainUpdatePanel` | `Public ReadOnly Property MainUpdatePanel As UpdatePanel` | Typed accessor for the master page's primary `UpdatePanel`, used for partial-postback script registration. |
| `RenderClientScripts()` | `Protected Overrides Sub RenderClientScripts()` | Entry point invoked on `PreRender` that checks `FocusControl` and, if set, calls `RegisterFocusControlScript`. |
| `RegisterFocusControlScript(control)` | `Protected Sub RegisterFocusControlScript(control As Control)` | Builds the control-type-specific client-side selector, wraps it in a defensive `try/setTimeout/catch`, and registers it as the page's startup script. |

## Behavioral notes
- When `FocusControl` is `Nothing`, `RenderClientScripts` exits immediately and no focus script is registered at all.
- Selector construction branches on the control's runtime type name: Infragistics `WebDataInput` (`#igtxt<ClientID>`), `WebCombo` (`<ClientID with _ → x>_input`), `WebSchedule.WebDateChooser` (`<ClientID>_input`), `Button` (focus without select), `Infragistics.Web.UI.ListControls` (no script emitted), and any other type (`#<ClientID>` fallback).
- The registered script runs 100ms after load inside `try{...}catch(e){}`, so a control missing from the rendered DOM at focus time fails silently rather than breaking the page.

## Constraints and usage notes
- Consuming master pages must declare controls with the exact IDs expected by the typed accessors (`ScriptManager1`, `Banner`, `Menu`, `MenuTop`, `MessageLabel`, `ErrorLabel`, `MainUpdatePanel`) for those properties to resolve correctly.
- `Infragistics.Web.UI.ListControls` types never receive a focus script — callers targeting those types should not rely on `FocusControl` for them.

> **Note:** Statements marked with * were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts. Statements marked with ** could not be confirmed; treat as unknown until verified.

## Sources
- `SAIF.Presentation.Web.Core.Infragistics111/AppViewMasterPageBase.vb`
