V.8
The Page_DataRendering server event allows you to place a custom message directly above the field title column. One of my project uses multi-pages. The student's name appears in the view and edit screens on the first page, but is, of course, is not visible under the other 6 tabs where the remaining pages of data are shown.
My client wanted the name visible at all times. The page data rendering event made it quick and easy work. Here is the code I used for the View and the Edit pages:
View Page
// Page Data Rendering event
function Page_DataRendering(&$header) {
global $student;
$header = "Viewing Record of: ".$student->First_Name->ViewValue .' '. $student->Last_Name->ViewValue;
if ($student->Marital_Status->ViewValue == 'Married Filing Jointly')
{
$header .= ' & '. $student->Spouse_First_Name->ViewValue .' '. $student->Spouse_Last_Name->ViewValue ;
}
}
And for the Edit Page:
// Page Data Rendering event
function Page_DataRendering(&$header) {
global $student;
$header = "Editing Record of: ".$student->First_Name->EditValue .' '. $student->Last_Name->EditValue;
if ($student->Marital_Status->EditValue == 'Married Filing Jointly')
{
$header .= ' & '. $student->Spouse_First_Name->EditValue .' '. $student->Spouse_Last_Name->EditValue ;
}
}
Notice the global $student. This makes the student data available to the function. In the view page, $student->Last_Name->ViewValue is in scope, while in the edit page, $student->Last_Name->EditValue is in scope.
That's all there is to it.