Skip to content

Retrieve help text for a screen field

clsHelpText.GetHelpText is the public shared factory method that retrieves a single, read-only help-text record for a given application code and reference key value. HoverHelp renders content from an already-retrieved clsHelpText instance rather than calling this factory itself, but this factory is the documented retrieval entry point of the business object.

Field Value
Operation ID OP-AJAX-004
Trigger Consuming presentation code calls clsHelpText.GetHelpText(inDataportal, inApplicationCode, inReferenceKeyValue)
Inputs IDataPortalInfo, application code, reference key value
Outputs A populated, read-only clsHelpText instance
Primary components clsHelpText.GetHelpText, clsHelpText.Criteria, clsHelpText.BeforeRetrieve, clsHelpText.AfterRetrieve, clsHelpText.Fill
Entry point SAIF.Presentation.Web.Controls.AJAX.Infragistics103\clsHelpText.vb

Steps

  1. Constructs a Criteria(inDataportal, inApplicationCode, inReferenceKeyValue) object.
  2. Calls inDataportal.DataAccessLayer.RetrieveObject(criteria), which invokes the BOF data-portal pipeline: BeforeRetrieve builds an IDataRequest with SQLStatement = MyCriteria.RetrieveSQL and adds bind parameters ApplicationCode (max length 5) and ReferenceKeyValue (max length 40) — executing SQL-HELP-001 against APPLICATION_HELP_MASTER and APPLICATION_HELP_DETAIL.
  3. AfterRetrieve casts the result to clsSAIFDataReader, reads the first row, and calls Fill() to populate ApplicationCode, ReferenceKeyDescription, ReferenceKeyValue, HelpText; marks the object MarkOld() (BOF convention for "unmodified, loaded from DB").
  4. On failure to find a matching row: Reader.Read() returns False, Fill() is skipped, and the object's fields retain their default (empty-string) initial values.
  5. No update/insert/delete paths exist for this object — CreateSQL, InsertSQL, UpdateSQL, DeleteSQL all Throw New ApplicationException(BOC.Messages.InvalidSQLProperty); this object is retrieve-only by design.

No business rules are enforced by this operation — this is a lookup-only reference object with no AddErrorMessage/business-rule calls in the reviewed code.

Process flow

The following diagram visualizes the retrieval sequence.

flowchart TD
    Start([Consuming code calls GetHelpText]) --> Criteria[Construct Criteria with ApplicationCode/ReferenceKeyValue]
    Criteria --> Retrieve[DataAccessLayer.RetrieveObject]
    Retrieve --> Before[BeforeRetrieve binds parameters, sets RetrieveSQL]
    Before --> Execute[Execute SQL-HELP-001 against Oracle*]
    Execute --> After{Row returned?}
    After -->|Yes| Fill[AfterRetrieve.Fill populates fields, MarkOld]
    After -->|No| Empty([Object retains default empty values])
    Fill --> Return([Return populated clsHelpText])

Failure and edge-case behavior

  • No matching row for the given application code/reference key: Reader.Read() returns False; the returned object's fields remain at their default empty-string values rather than raising an error.
  • Any attempt to Save()/Delete() this object raises ApplicationException(BOC.Messages.InvalidSQLProperty), since no create/update/delete SQL exists.

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.Controls.AJAX.Infragistics103\clsHelpText.vb
  • SAIF.Presentation.Web.Controls.AJAX.Infragistics103\HoverHelp.vb