Your IP : 216.73.217.79


Current Path : /var/www/cesa.co.za/cceconvenors/
Upload File :
Current File : /var/www/cesa.co.za/cceconvenors/cstArchivedStudents2017view.php

<?php
session_start(); // Initialize Session data
ob_start(); // Turn on output buffering
?>
<?php include "ewcfg7.php" ?>
<?php include "ewmysql7.php" ?>
<?php include "phpfn7.php" ?>
<?php include "cstArchivedStudents2017info.php" ?>
<?php include "CCEFacilitatorUsersinfo.php" ?>
<?php include "userfn7.php" ?>
<?php
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // Always modified
header("Cache-Control: private, no-store, no-cache, must-revalidate"); // HTTP/1.1 
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache"); // HTTP/1.0
?>
<?php

// Create page object
$cstArchivedStudents2017_view = new ccstArchivedStudents2017_view();
$Page =& $cstArchivedStudents2017_view;

// Page init
$cstArchivedStudents2017_view->Page_Init();

// Page main
$cstArchivedStudents2017_view->Page_Main();
?>
<?php include "header.php" ?>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
<script type="text/javascript">
<!--

// Create page object
var cstArchivedStudents2017_view = new ew_Page("cstArchivedStudents2017_view");

// page properties
cstArchivedStudents2017_view.PageID = "view"; // page ID
cstArchivedStudents2017_view.FormID = "fcstArchivedStudents2017view"; // form ID
var EW_PAGE_ID = cstArchivedStudents2017_view.PageID; // for backward compatibility

// extend page with Form_CustomValidate function
cstArchivedStudents2017_view.Form_CustomValidate =  
 function(fobj) { // DO NOT CHANGE THIS LINE!

 	// Your custom validation code here, return false if invalid. 
 	return true;
 }
<?php if (EW_CLIENT_VALIDATE) { ?>
cstArchivedStudents2017_view.ValidateRequired = true; // uses JavaScript validation
<?php } else { ?>
cstArchivedStudents2017_view.ValidateRequired = false; // no JavaScript validation
<?php } ?>

//-->
</script>
<script language="JavaScript" type="text/javascript">
<!--

// Write your client script here, no need to add script tags.
// To include another .js script, use:
// ew_ClientScriptInclude("my_javascript.js"); 
//-->

</script>
<?php } ?>
<p><span class="phpmaker"><?php echo $Language->Phrase("View") ?>&nbsp;<?php echo $Language->Phrase("TblTypeCUSTOMVIEW") ?><?php echo $cstArchivedStudents2017->TableCaption() ?>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
&nbsp;&nbsp;<a href="<?php echo $cstArchivedStudents2017_view->ExportPrintUrl ?>"><img src="images/print.gif" alt="<?php echo ew_HtmlEncode($Language->Phrase("PrinterFriendly")) ?>" title="<?php echo ew_HtmlEncode($Language->Phrase("PrinterFriendly")) ?>" width="16" height="16" border="0"></a>
&nbsp;&nbsp;<a href="<?php echo $cstArchivedStudents2017_view->ExportExcelUrl ?>"><img src='images/exportxls.gif' alt='<?php echo ew_HtmlEncode($Language->Phrase("ExportToExcel")) ?>' title='<?php echo ew_HtmlEncode($Language->Phrase("ExportToExcel")) ?>' width='16' height='16' border='0'></a>
&nbsp;&nbsp;<a href="<?php echo $cstArchivedStudents2017_view->ExportWordUrl ?>"><img src='images/exportdoc.gif' alt='<?php echo ew_HtmlEncode($Language->Phrase("ExportToWord")) ?>' title='<?php echo ew_HtmlEncode($Language->Phrase("ExportToWord")) ?>' width='16' height='16' border='0'></a>
&nbsp;&nbsp;<a name="emf_cstArchivedStudents2017" id="emf_cstArchivedStudents2017" href="javascript:void(0);" onclick="ew_EmailDialogShow({lnk:'emf_cstArchivedStudents2017',hdr:ewLanguage.Phrase('ExportToEmail'),key:<?php echo ew_ArrayToJsonAttr($cstArchivedStudents2017_view->arRecKey) ?>,sel:false});"><img src='images/exportemail.gif' alt='<?php echo ew_HtmlEncode($Language->Phrase("ExportToEmail")) ?>' title='<?php echo ew_HtmlEncode($Language->Phrase("ExportToEmail")) ?>' width='16' height='16' border='0'></a>
<?php } ?>
<br><br>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
<a href="<?php echo $cstArchivedStudents2017_view->ListUrl ?>"><?php echo $Language->Phrase("BackToList") ?></a>&nbsp;
<?php if ($Security->IsLoggedIn()) { ?>
<a href="cstSubmittedAssignArchivedlist.php?<?php echo EW_TABLE_SHOW_MASTER ?>=cstArchivedStudents2017&CCEStudentID=<?php echo urlencode(strval($cstArchivedStudents2017->CCEStudentID->CurrentValue)) ?>"><?php echo $Language->Phrase("ViewPageDetailLink") ?><?php echo $Language->TablePhrase("cstSubmittedAssignArchived", "TblCaption") ?>
</a>
&nbsp;
<?php } ?>
<?php } ?>
</span></p>
<?php
if (EW_DEBUG_ENABLED)
	echo ew_DebugMsg();
$cstArchivedStudents2017_view->ShowMessage();
?>
<p>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
<form name="ewpagerform" id="ewpagerform" class="ewForm" action="<?php echo ew_CurrentPage() ?>">
<table border="0" cellspacing="0" cellpadding="0" class="ewPager">
	<tr>
		<td nowrap>
<?php if (!isset($cstArchivedStudents2017_view->Pager)) $cstArchivedStudents2017_view->Pager = new cPrevNextPager($cstArchivedStudents2017_view->lStartRec, $cstArchivedStudents2017_view->lDisplayRecs, $cstArchivedStudents2017_view->lTotalRecs) ?>
<?php if ($cstArchivedStudents2017_view->Pager->RecordCount > 0) { ?>
	<table border="0" cellspacing="0" cellpadding="0"><tr><td><span class="phpmaker"><?php echo $Language->Phrase("Page") ?>&nbsp;</span></td>
<!--first page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->FirstButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->FirstButton->Start ?>"><img src="images/first.gif" alt="<?php echo $Language->Phrase("PagerFirst") ?>" width="16" height="16" border="0"></a></td>
	<?php } else { ?>
	<td><img src="images/firstdisab.gif" alt="<?php echo $Language->Phrase("PagerFirst") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--previous page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->PrevButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->PrevButton->Start ?>"><img src="images/prev.gif" alt="<?php echo $Language->Phrase("PagerPrevious") ?>" width="16" height="16" border="0"></a></td>
	<?php } else { ?>
	<td><img src="images/prevdisab.gif" alt="<?php echo $Language->Phrase("PagerPrevious") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--current page number-->
	<td><input type="text" name="<?php echo EW_TABLE_PAGE_NO ?>" id="<?php echo EW_TABLE_PAGE_NO ?>" value="<?php echo $cstArchivedStudents2017_view->Pager->CurrentPage ?>" size="4"></td>
<!--next page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->NextButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->NextButton->Start ?>"><img src="images/next.gif" alt="<?php echo $Language->Phrase("PagerNext") ?>" width="16" height="16" border="0"></a></td>	
	<?php } else { ?>
	<td><img src="images/nextdisab.gif" alt="<?php echo $Language->Phrase("PagerNext") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--last page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->LastButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->LastButton->Start ?>"><img src="images/last.gif" alt="<?php echo $Language->Phrase("PagerLast") ?>" width="16" height="16" border="0"></a></td>	
	<?php } else { ?>
	<td><img src="images/lastdisab.gif" alt="<?php echo $Language->Phrase("PagerLast") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
	<td><span class="phpmaker">&nbsp;<?php echo $Language->Phrase("of") ?>&nbsp;<?php echo $cstArchivedStudents2017_view->Pager->PageCount ?></span></td>
	</tr></table>
<?php } else { ?>
	<?php if ($cstArchivedStudents2017_view->sSrchWhere == "0=101") { ?>
	<span class="phpmaker"><?php echo $Language->Phrase("EnterSearchCriteria") ?></span>
	<?php } else { ?>
	<span class="phpmaker"><?php echo $Language->Phrase("NoRecord") ?></span>
	<?php } ?>
<?php } ?>
		</td>
	</tr>
</table>
</form>
<br>
<?php } ?>
<table cellspacing="0" class="ewGrid"><tr><td class="ewGridContent">
<div class="ewGridMiddlePanel">
<table cellspacing="0" class="ewTable">
<?php if ($cstArchivedStudents2017->Title->Visible) { // Title ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Title->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Title->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Title->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Title->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->FirstName->Visible) { // FirstName ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->FirstName->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->FirstName->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->FirstName->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->FirstName->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Surname->Visible) { // Surname ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Surname->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Surname->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Surname->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Surname->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->KnownAs->Visible) { // KnownAs ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->KnownAs->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->KnownAs->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->KnownAs->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->KnownAs->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Organisation->Visible) { // Organisation ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Organisation->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Organisation->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Organisation->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Organisation->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->OrganisationType->Visible) { // OrganisationType ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->OrganisationType->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->OrganisationType->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->OrganisationType->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->OrganisationType->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->StudentNumber->Visible) { // StudentNumber ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->StudentNumber->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->StudentNumber->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->StudentNumber->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->StudentNumber->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->CCEFacilitatorID->Visible) { // CCEFacilitatorID ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->CCEFacilitatorID->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->CCEFacilitatorID->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->CCEFacilitatorID->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->CCEFacilitatorID->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Project->Visible) { // Project ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Project->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Project->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Project->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Project->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->ProjectDiscipline->Visible) { // ProjectDiscipline ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->ProjectDiscipline->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->ProjectDiscipline->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->ProjectDiscipline->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->ProjectDiscipline->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->IDNumber->Visible) { // IDNumber ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->IDNumber->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->IDNumber->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->IDNumber->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->IDNumber->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->ECSANumber->Visible) { // ECSANumber ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->ECSANumber->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->ECSANumber->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->ECSANumber->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->ECSANumber->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Age->Visible) { // Age ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Age->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Age->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Age->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Age->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HighestQual->Visible) { // HighestQual ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HighestQual->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HighestQual->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HighestQual->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HighestQual->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->AreaDiscipline->Visible) { // AreaDiscipline ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->AreaDiscipline->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->AreaDiscipline->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->AreaDiscipline->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->AreaDiscipline->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Telephone->Visible) { // Telephone ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Telephone->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Telephone->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Telephone->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Telephone->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Cellphone->Visible) { // Cellphone ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Cellphone->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Cellphone->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Cellphone->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Cellphone->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->EmailAddress->Visible) { // EmailAddress ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->EmailAddress->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->EmailAddress->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->EmailAddress->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->EmailAddress->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Designation->Visible) { // Designation ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Designation->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Designation->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Designation->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Designation->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->Department->Visible) { // Department ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->Department->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->Department->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->Department->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->Department->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->CVFile->Visible) { // CVFile ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->CVFile->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->CVFile->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->CVFile->HrefValue <> "" || $cstArchivedStudents2017->CVFile->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->CVFile->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->CVFile->HrefValue ?>"><?php echo $cstArchivedStudents2017->CVFile->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->CVFile->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->CVFile->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->QualCertificate1->Visible) { // QualCertificate1 ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->QualCertificate1->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->QualCertificate1->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->QualCertificate1->HrefValue <> "" || $cstArchivedStudents2017->QualCertificate1->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate1->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->QualCertificate1->HrefValue ?>"><?php echo $cstArchivedStudents2017->QualCertificate1->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate1->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->QualCertificate1->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->QualCertificate2->Visible) { // QualCertificate2 ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->QualCertificate2->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->QualCertificate2->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->QualCertificate2->HrefValue <> "" || $cstArchivedStudents2017->QualCertificate2->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate2->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->QualCertificate2->HrefValue ?>"><?php echo $cstArchivedStudents2017->QualCertificate2->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate2->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->QualCertificate2->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->QualCertificate3->Visible) { // QualCertificate3 ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->QualCertificate3->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->QualCertificate3->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->QualCertificate3->HrefValue <> "" || $cstArchivedStudents2017->QualCertificate3->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate3->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->QualCertificate3->HrefValue ?>"><?php echo $cstArchivedStudents2017->QualCertificate3->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->QualCertificate3->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->QualCertificate3->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MemorandumFile->Visible) { // MemorandumFile ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MemorandumFile->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MemorandumFile->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->MemorandumFile->HrefValue <> "" || $cstArchivedStudents2017->MemorandumFile->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->MemorandumFile->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->MemorandumFile->HrefValue ?>"><?php echo $cstArchivedStudents2017->MemorandumFile->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->MemorandumFile->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->MemorandumFile->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->AgreementFile->Visible) { // AgreementFile ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->AgreementFile->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->AgreementFile->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->AgreementFile->HrefValue <> "" || $cstArchivedStudents2017->AgreementFile->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->AgreementFile->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->AgreementFile->HrefValue ?>"><?php echo $cstArchivedStudents2017->AgreementFile->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->AgreementFile->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->AgreementFile->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->OrderNo->Visible) { // OrderNo ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->OrderNo->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->OrderNo->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->OrderNo->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->OrderNo->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->WebUsername->Visible) { // WebUsername ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->WebUsername->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->WebUsername->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->WebUsername->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->WebUsername->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->WebPassword->Visible) { // WebPassword ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->WebPassword->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->WebPassword->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->WebPassword->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->WebPassword->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MentorName->Visible) { // MentorName ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MentorName->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MentorName->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->MentorName->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->MentorName->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MentorDesig->Visible) { // MentorDesig ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MentorDesig->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MentorDesig->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->MentorDesig->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->MentorDesig->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MentorTel->Visible) { // MentorTel ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MentorTel->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MentorTel->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->MentorTel->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->MentorTel->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MentorCell->Visible) { // MentorCell ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MentorCell->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MentorCell->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->MentorCell->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->MentorCell->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->MentorEmail->Visible) { // MentorEmail ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->MentorEmail->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->MentorEmail->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->MentorEmail->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->MentorEmail->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HRManagerName->Visible) { // HRManagerName ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HRManagerName->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HRManagerName->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HRManagerName->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HRManagerName->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HRManagerDesignation->Visible) { // HRManagerDesignation ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HRManagerDesignation->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HRManagerDesignation->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HRManagerDesignation->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HRManagerDesignation->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HRManagerTelNo->Visible) { // HRManagerTelNo ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HRManagerTelNo->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HRManagerTelNo->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HRManagerTelNo->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HRManagerTelNo->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HRManagerCellNo->Visible) { // HRManagerCellNo ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HRManagerCellNo->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HRManagerCellNo->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HRManagerCellNo->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HRManagerCellNo->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->HRManagerEmail->Visible) { // HRManagerEmail ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->HRManagerEmail->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->HRManagerEmail->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->HRManagerEmail->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->HRManagerEmail->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->LengthEmploy->Visible) { // LengthEmploy ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->LengthEmploy->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->LengthEmploy->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->LengthEmploy->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->LengthEmploy->ViewValue ?></div></td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->ResultLetter->Visible) { // ResultLetter ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->ResultLetter->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->ResultLetter->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->ResultLetter->HrefValue <> "" || $cstArchivedStudents2017->ResultLetter->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->ResultLetter->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->ResultLetter->HrefValue ?>"><?php echo $cstArchivedStudents2017->ResultLetter->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->ResultLetter->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->ResultLetter->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->IDFile->Visible) { // IDFile ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->IDFile->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->IDFile->CellAttributes() ?>>
<?php if ($cstArchivedStudents2017->IDFile->HrefValue <> "" || $cstArchivedStudents2017->IDFile->TooltipValue <> "") { ?>
<?php if (!empty($cstArchivedStudents2017->IDFile->Upload->DbValue)) { ?>
<a href="<?php echo $cstArchivedStudents2017->IDFile->HrefValue ?>"><?php echo $cstArchivedStudents2017->IDFile->ViewValue ?></a>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } else { ?>
<?php if (!empty($cstArchivedStudents2017->IDFile->Upload->DbValue)) { ?>
<?php echo $cstArchivedStudents2017->IDFile->ViewValue ?>
<?php } elseif (!in_array($cstArchivedStudents2017->CurrentAction, array("I", "edit", "gridedit"))) { ?>	
&nbsp;
<?php } ?>
<?php } ?>
</td>
	</tr>
<?php } ?>
<?php if ($cstArchivedStudents2017->ReasonForLeaving->Visible) { // ReasonForLeaving ?>
	<tr<?php echo $cstArchivedStudents2017->RowAttributes() ?>>
		<td class="ewTableHeader"><?php echo $cstArchivedStudents2017->ReasonForLeaving->FldCaption() ?></td>
		<td<?php echo $cstArchivedStudents2017->ReasonForLeaving->CellAttributes() ?>>
<div<?php echo $cstArchivedStudents2017->ReasonForLeaving->ViewAttributes() ?>><?php echo $cstArchivedStudents2017->ReasonForLeaving->ViewValue ?></div></td>
	</tr>
<?php } ?>
</table>
</div>
</td></tr></table>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
<br>
<form name="ewpagerform" id="ewpagerform" class="ewForm" action="<?php echo ew_CurrentPage() ?>">
<table border="0" cellspacing="0" cellpadding="0" class="ewPager">
	<tr>
		<td nowrap>
<?php if (!isset($cstArchivedStudents2017_view->Pager)) $cstArchivedStudents2017_view->Pager = new cPrevNextPager($cstArchivedStudents2017_view->lStartRec, $cstArchivedStudents2017_view->lDisplayRecs, $cstArchivedStudents2017_view->lTotalRecs) ?>
<?php if ($cstArchivedStudents2017_view->Pager->RecordCount > 0) { ?>
	<table border="0" cellspacing="0" cellpadding="0"><tr><td><span class="phpmaker"><?php echo $Language->Phrase("Page") ?>&nbsp;</span></td>
<!--first page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->FirstButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->FirstButton->Start ?>"><img src="images/first.gif" alt="<?php echo $Language->Phrase("PagerFirst") ?>" width="16" height="16" border="0"></a></td>
	<?php } else { ?>
	<td><img src="images/firstdisab.gif" alt="<?php echo $Language->Phrase("PagerFirst") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--previous page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->PrevButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->PrevButton->Start ?>"><img src="images/prev.gif" alt="<?php echo $Language->Phrase("PagerPrevious") ?>" width="16" height="16" border="0"></a></td>
	<?php } else { ?>
	<td><img src="images/prevdisab.gif" alt="<?php echo $Language->Phrase("PagerPrevious") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--current page number-->
	<td><input type="text" name="<?php echo EW_TABLE_PAGE_NO ?>" id="<?php echo EW_TABLE_PAGE_NO ?>" value="<?php echo $cstArchivedStudents2017_view->Pager->CurrentPage ?>" size="4"></td>
<!--next page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->NextButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->NextButton->Start ?>"><img src="images/next.gif" alt="<?php echo $Language->Phrase("PagerNext") ?>" width="16" height="16" border="0"></a></td>	
	<?php } else { ?>
	<td><img src="images/nextdisab.gif" alt="<?php echo $Language->Phrase("PagerNext") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
<!--last page button-->
	<?php if ($cstArchivedStudents2017_view->Pager->LastButton->Enabled) { ?>
	<td><a href="<?php echo $cstArchivedStudents2017_view->PageUrl() ?>start=<?php echo $cstArchivedStudents2017_view->Pager->LastButton->Start ?>"><img src="images/last.gif" alt="<?php echo $Language->Phrase("PagerLast") ?>" width="16" height="16" border="0"></a></td>	
	<?php } else { ?>
	<td><img src="images/lastdisab.gif" alt="<?php echo $Language->Phrase("PagerLast") ?>" width="16" height="16" border="0"></td>
	<?php } ?>
	<td><span class="phpmaker">&nbsp;<?php echo $Language->Phrase("of") ?>&nbsp;<?php echo $cstArchivedStudents2017_view->Pager->PageCount ?></span></td>
	</tr></table>
<?php } else { ?>
	<?php if ($cstArchivedStudents2017_view->sSrchWhere == "0=101") { ?>
	<span class="phpmaker"><?php echo $Language->Phrase("EnterSearchCriteria") ?></span>
	<?php } else { ?>
	<span class="phpmaker"><?php echo $Language->Phrase("NoRecord") ?></span>
	<?php } ?>
<?php } ?>
		</td>
	</tr>
</table>
</form>
<?php } ?>
<p>
<?php if ($cstArchivedStudents2017->Export == "") { ?>
<script language="JavaScript" type="text/javascript">
<!--

// Write your table-specific startup script here
// document.write("page loaded");
//-->

</script>
<?php } ?>
<?php include "footer.php" ?>
<?php
$cstArchivedStudents2017_view->Page_Terminate();
?>
<?php

//
// Page class
//
class ccstArchivedStudents2017_view {

	// Page ID
	var $PageID = 'view';

	// Table name
	var $TableName = 'cstArchivedStudents2017';

	// Page object name
	var $PageObjName = 'cstArchivedStudents2017_view';

	// Page name
	function PageName() {
		return ew_CurrentPage();
	}

	// Page URL
	function PageUrl() {
		$PageUrl = ew_CurrentPage() . "?";
		global $cstArchivedStudents2017;
		if ($cstArchivedStudents2017->UseTokenInUrl) $PageUrl .= "t=" . $cstArchivedStudents2017->TableVar . "&"; // Add page token
		return $PageUrl;
	}

	// Page URLs
	var $AddUrl;
	var $EditUrl;
	var $CopyUrl;
	var $DeleteUrl;
	var $ViewUrl;
	var $ListUrl;

	// Export URLs
	var $ExportPrintUrl;
	var $ExportHtmlUrl;
	var $ExportExcelUrl;
	var $ExportWordUrl;
	var $ExportXmlUrl;
	var $ExportCsvUrl;

	// Update URLs
	var $InlineAddUrl;
	var $InlineCopyUrl;
	var $InlineEditUrl;
	var $GridAddUrl;
	var $GridEditUrl;
	var $MultiDeleteUrl;
	var $MultiUpdateUrl;

	// Message
	function getMessage() {
		return @$_SESSION[EW_SESSION_MESSAGE];
	}

	function setMessage($v) {
		if (@$_SESSION[EW_SESSION_MESSAGE] <> "") { // Append
			$_SESSION[EW_SESSION_MESSAGE] .= "<br>" . $v;
		} else {
			$_SESSION[EW_SESSION_MESSAGE] = $v;
		}
	}

	// Show message
	function ShowMessage() {
		$sMessage = $this->getMessage();
		$this->Message_Showing($sMessage);
		if ($sMessage <> "") { // Message in Session, display
			echo "<p><span class=\"ewMessage\">" . $sMessage . "</span></p>";
			$_SESSION[EW_SESSION_MESSAGE] = ""; // Clear message in Session
		}
	}

	// Validate page request
	function IsPageRequest() {
		global $objForm, $cstArchivedStudents2017;
		if ($cstArchivedStudents2017->UseTokenInUrl) {
			if ($objForm)
				return ($cstArchivedStudents2017->TableVar == $objForm->GetValue("t"));
			if (@$_GET["t"] <> "")
				return ($cstArchivedStudents2017->TableVar == $_GET["t"]);
		} else {
			return TRUE;
		}
	}

	//
	// Page class constructor
	//
	function __construct() {
		global $conn, $Language;

		// Language object
		$Language = new cLanguage();

		// Table object (cstArchivedStudents2017)
		$GLOBALS["cstArchivedStudents2017"] = new ccstArchivedStudents2017();

		// Table object (CCEFacilitatorUsers)
		$GLOBALS['CCEFacilitatorUsers'] = new cCCEFacilitatorUsers();

		// Page ID
		if (!defined("EW_PAGE_ID"))
			define("EW_PAGE_ID", 'view', TRUE);

		// Table name (for backward compatibility)
		if (!defined("EW_TABLE_NAME"))
			define("EW_TABLE_NAME", 'cstArchivedStudents2017', TRUE);

		// Start timer
		$GLOBALS["gsTimer"] = new cTimer();

		// Open connection
		$conn = ew_Connect();
	}

	// 
	//  Page_Init
	//
	function Page_Init() {
		global $gsExport, $gsExportFile, $UserProfile, $Language, $Security, $objForm;
		global $cstArchivedStudents2017;

		// Security
		$Security = new cAdvancedSecurity();
		if (!$Security->IsLoggedIn()) $Security->AutoLogin();
		if (!$Security->IsLoggedIn()) {
			$Security->SaveLastUrl();
			$this->Page_Terminate("login.php");
		}

		// Get export parameters
		if (@$_GET["export"] <> "") {
			$cstArchivedStudents2017->Export = $_GET["export"];
		} elseif (ew_IsHttpPost()) {
			if (@$_POST["exporttype"] <> "")
				$cstArchivedStudents2017->Export = $_POST["exporttype"];
		} else {
			$cstArchivedStudents2017->setExportReturnUrl(ew_CurrentUrl());
		}
		$gsExport = $cstArchivedStudents2017->Export; // Get export parameter, used in header
		$gsExportFile = $cstArchivedStudents2017->TableVar; // Get export file, used in header
		if (@$_GET["CCEStudentID"] <> "") {
			if ($gsExportFile <> "") $gsExportFile .= "_";
			$gsExportFile .= ew_StripSlashes($_GET["CCEStudentID"]);
		}
		if ($cstArchivedStudents2017->Export == "excel") {
			header('Content-Type: application/vnd.ms-excel');
			header('Content-Disposition: attachment; filename=' . $gsExportFile .'.xls');
		}
		if ($cstArchivedStudents2017->Export == "word") {
			header('Content-Type: application/vnd.ms-word');
			header('Content-Disposition: attachment; filename=' . $gsExportFile .'.doc');
		}

		// Global Page Loading event (in userfn*.php)
		Page_Loading();

		// Page Load event
		$this->Page_Load();
	}

	//
	// Page_Terminate
	//
	function Page_Terminate($url = "") {
		global $conn;

		// Page Unload event
		$this->Page_Unload();

		// Global Page Unloaded event (in userfn*.php)
		Page_Unloaded();

		 // Close connection
		$conn->Close();

		// Go to URL if specified
		$this->Page_Redirecting($url);
		if ($url <> "") {
			if (!EW_DEBUG_ENABLED && ob_get_length())
				ob_end_clean();
			header("Location: " . $url);
		}
		exit();
	}
	var $lDisplayRecs = 1;
	var $lStartRec;
	var $lStopRec;
	var $lTotalRecs = 0;
	var $lRecRange = 10;
	var $lRecCnt;
	var $arRecKey = array();

	//
	// Page main
	//
	function Page_Main() {
		global $Language, $cstArchivedStudents2017;

		// Load current record
		$bLoadCurrentRecord = FALSE;
		$sReturnUrl = "";
		$bMatchRecord = FALSE;
		if ($this->IsPageRequest()) { // Validate request
			if (@$_GET["CCEStudentID"] <> "") {
				$cstArchivedStudents2017->CCEStudentID->setQueryStringValue($_GET["CCEStudentID"]);
				$this->arRecKey["CCEStudentID"] = $cstArchivedStudents2017->CCEStudentID->QueryStringValue;
			} else {
				$bLoadCurrentRecord = TRUE;
			}

			// Get action
			$cstArchivedStudents2017->CurrentAction = "I"; // Display form
			switch ($cstArchivedStudents2017->CurrentAction) {
				case "I": // Get a record to display
					$this->lStartRec = 1; // Initialize start position
					if ($rs = $this->LoadRecordset()) // Load records
						$this->lTotalRecs = $rs->RecordCount(); // Get record count
					if ($this->lTotalRecs <= 0) { // No record found
						$this->setMessage($Language->Phrase("NoRecord")); // Set no record message
						$this->Page_Terminate("cstArchivedStudents2017list.php"); // Return to list page
					} elseif ($bLoadCurrentRecord) { // Load current record position
						$this->SetUpStartRec(); // Set up start record position

						// Point to current record
						if (intval($this->lStartRec) <= intval($this->lTotalRecs)) {
							$bMatchRecord = TRUE;
							$rs->Move($this->lStartRec-1);
						}
					} else { // Match key values
						while (!$rs->EOF) {
							if (strval($cstArchivedStudents2017->CCEStudentID->CurrentValue) == strval($rs->fields('CCEStudentID'))) {
								$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec); // Save record position
								$bMatchRecord = TRUE;
								break;
							} else {
								$this->lStartRec++;
								$rs->MoveNext();
							}
						}
					}
					if (!$bMatchRecord) {
						$this->setMessage($Language->Phrase("NoRecord")); // Set no record message
						$sReturnUrl = "cstArchivedStudents2017list.php"; // No matching record, return to list
					} else {
						$this->LoadRowValues($rs); // Load row values
					}
			}

			// Export data only
			if (in_array($cstArchivedStudents2017->Export, array("html","word","excel","xml","csv","email"))) {
				$this->ExportData();
				if ($cstArchivedStudents2017->Export <> "email")
					$this->Page_Terminate(); // Terminate response
				exit();
			}
		} else {
			$sReturnUrl = "cstArchivedStudents2017list.php"; // Not page request, return to list
		}
		if ($sReturnUrl <> "")
			$this->Page_Terminate($sReturnUrl);

		// Render row
		$cstArchivedStudents2017->RowType = EW_ROWTYPE_VIEW;
		$this->RenderRow();
	}

	// Set up starting record parameters
	function SetUpStartRec() {
		global $cstArchivedStudents2017;
		if ($this->lDisplayRecs == 0)
			return;
		if ($this->IsPageRequest()) { // Validate request
			if (@$_GET[EW_TABLE_START_REC] <> "") { // Check for "start" parameter
				$this->lStartRec = $_GET[EW_TABLE_START_REC];
				$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec);
			} elseif (@$_GET[EW_TABLE_PAGE_NO] <> "") {
				$this->nPageNo = $_GET[EW_TABLE_PAGE_NO];
				if (is_numeric($this->nPageNo)) {
					$this->lStartRec = ($this->nPageNo-1)*$this->lDisplayRecs+1;
					if ($this->lStartRec <= 0) {
						$this->lStartRec = 1;
					} elseif ($this->lStartRec >= intval(($this->lTotalRecs-1)/$this->lDisplayRecs)*$this->lDisplayRecs+1) {
						$this->lStartRec = intval(($this->lTotalRecs-1)/$this->lDisplayRecs)*$this->lDisplayRecs+1;
					}
					$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec);
				}
			}
		}
		$this->lStartRec = $cstArchivedStudents2017->getStartRecordNumber();

		// Check if correct start record counter
		if (!is_numeric($this->lStartRec) || $this->lStartRec == "") { // Avoid invalid start record counter
			$this->lStartRec = 1; // Reset start record counter
			$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec);
		} elseif (intval($this->lStartRec) > intval($this->lTotalRecs)) { // Avoid starting record > total records
			$this->lStartRec = intval(($this->lTotalRecs-1)/$this->lDisplayRecs)*$this->lDisplayRecs+1; // Point to last page first record
			$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec);
		} elseif (($this->lStartRec-1) % $this->lDisplayRecs <> 0) {
			$this->lStartRec = intval(($this->lStartRec-1)/$this->lDisplayRecs)*$this->lDisplayRecs+1; // Point to page boundary
			$cstArchivedStudents2017->setStartRecordNumber($this->lStartRec);
		}
	}

	// Load recordset
	function LoadRecordset($offset = -1, $rowcnt = -1) {
		global $conn, $cstArchivedStudents2017;

		// Call Recordset Selecting event
		$cstArchivedStudents2017->Recordset_Selecting($cstArchivedStudents2017->CurrentFilter);

		// Load List page SQL
		$sSql = $cstArchivedStudents2017->SelectSQL();
		if ($offset > -1 && $rowcnt > -1)
			$sSql .= " LIMIT $offset, $rowcnt";

		// Load recordset
		$rs = ew_LoadRecordset($sSql);

		// Call Recordset Selected event
		$cstArchivedStudents2017->Recordset_Selected($rs);
		return $rs;
	}

	// Load row based on key values
	function LoadRow() {
		global $conn, $Security, $cstArchivedStudents2017;
		$sFilter = $cstArchivedStudents2017->KeyFilter();

		// Call Row Selecting event
		$cstArchivedStudents2017->Row_Selecting($sFilter);

		// Load SQL based on filter
		$cstArchivedStudents2017->CurrentFilter = $sFilter;
		$sSql = $cstArchivedStudents2017->SQL();
		$res = FALSE;
		$rs = ew_LoadRecordset($sSql);
		if ($rs && !$rs->EOF) {
			$res = TRUE;
			$this->LoadRowValues($rs); // Load row values

			// Call Row Selected event
			$cstArchivedStudents2017->Row_Selected($rs);
			$rs->Close();
		}
		return $res;
	}

	// Load row values from recordset
	function LoadRowValues(&$rs) {
		global $conn, $cstArchivedStudents2017;
		$cstArchivedStudents2017->CCEStudentID->setDbValue($rs->fields('CCEStudentID'));
		$cstArchivedStudents2017->Title->setDbValue($rs->fields('Title'));
		$cstArchivedStudents2017->FirstName->setDbValue($rs->fields('FirstName'));
		$cstArchivedStudents2017->Surname->setDbValue($rs->fields('Surname'));
		$cstArchivedStudents2017->KnownAs->setDbValue($rs->fields('KnownAs'));
		$cstArchivedStudents2017->Organisation->setDbValue($rs->fields('Organisation'));
		$cstArchivedStudents2017->OrganisationType->setDbValue($rs->fields('OrganisationType'));
		$cstArchivedStudents2017->StudentNumber->setDbValue($rs->fields('StudentNumber'));
		$cstArchivedStudents2017->CCEFacilitatorID->setDbValue($rs->fields('CCEFacilitatorID'));
		$cstArchivedStudents2017->Project->setDbValue($rs->fields('Project'));
		$cstArchivedStudents2017->ProjectDiscipline->setDbValue($rs->fields('ProjectDiscipline'));
		$cstArchivedStudents2017->IDNumber->setDbValue($rs->fields('IDNumber'));
		$cstArchivedStudents2017->ECSANumber->setDbValue($rs->fields('ECSANumber'));
		$cstArchivedStudents2017->Age->setDbValue($rs->fields('Age'));
		$cstArchivedStudents2017->HighestQual->setDbValue($rs->fields('HighestQual'));
		$cstArchivedStudents2017->AreaDiscipline->setDbValue($rs->fields('AreaDiscipline'));
		$cstArchivedStudents2017->Telephone->setDbValue($rs->fields('Telephone'));
		$cstArchivedStudents2017->Cellphone->setDbValue($rs->fields('Cellphone'));
		$cstArchivedStudents2017->EmailAddress->setDbValue($rs->fields('EmailAddress'));
		$cstArchivedStudents2017->HomeAddress->setDbValue($rs->fields('HomeAddress'));
		$cstArchivedStudents2017->WorkAddress->setDbValue($rs->fields('WorkAddress'));
		$cstArchivedStudents2017->PostalAddress->setDbValue($rs->fields('PostalAddress'));
		$cstArchivedStudents2017->Designation->setDbValue($rs->fields('Designation'));
		$cstArchivedStudents2017->Department->setDbValue($rs->fields('Department'));
		$cstArchivedStudents2017->CESAAccountNo->setDbValue($rs->fields('CESAAccountNo'));
		$cstArchivedStudents2017->VATNo->setDbValue($rs->fields('VATNo'));
		$cstArchivedStudents2017->DietaryRequirements->setDbValue($rs->fields('DietaryRequirements'));
		$cstArchivedStudents2017->CVFile->Upload->DbValue = $rs->fields('CVFile');
		$cstArchivedStudents2017->QualCertificate1->Upload->DbValue = $rs->fields('QualCertificate1');
		$cstArchivedStudents2017->QualCertificate2->Upload->DbValue = $rs->fields('QualCertificate2');
		$cstArchivedStudents2017->QualCertificate3->Upload->DbValue = $rs->fields('QualCertificate3');
		$cstArchivedStudents2017->MemorandumFile->Upload->DbValue = $rs->fields('MemorandumFile');
		$cstArchivedStudents2017->AgreementFile->Upload->DbValue = $rs->fields('AgreementFile');
		$cstArchivedStudents2017->OrderNo->setDbValue($rs->fields('OrderNo'));
		$cstArchivedStudents2017->BookedByName->setDbValue($rs->fields('BookedByName'));
		$cstArchivedStudents2017->BookedByDesignation->setDbValue($rs->fields('BookedByDesignation'));
		$cstArchivedStudents2017->BookedByTelNo->setDbValue($rs->fields('BookedByTelNo'));
		$cstArchivedStudents2017->BookedByFaxNo->setDbValue($rs->fields('BookedByFaxNo'));
		$cstArchivedStudents2017->BookedByCellNo->setDbValue($rs->fields('BookedByCellNo'));
		$cstArchivedStudents2017->BookedByEmail->setDbValue($rs->fields('BookedByEmail'));
		$cstArchivedStudents2017->WebUsername->setDbValue($rs->fields('WebUsername'));
		$cstArchivedStudents2017->WebPassword->setDbValue($rs->fields('WebPassword'));
		$cstArchivedStudents2017->MentorName->setDbValue($rs->fields('MentorName'));
		$cstArchivedStudents2017->MentorDesig->setDbValue($rs->fields('MentorDesig'));
		$cstArchivedStudents2017->MentorTel->setDbValue($rs->fields('MentorTel'));
		$cstArchivedStudents2017->MentorCell->setDbValue($rs->fields('MentorCell'));
		$cstArchivedStudents2017->MentorEmail->setDbValue($rs->fields('MentorEmail'));
		$cstArchivedStudents2017->HRManagerName->setDbValue($rs->fields('HRManagerName'));
		$cstArchivedStudents2017->HRManagerDesignation->setDbValue($rs->fields('HRManagerDesignation'));
		$cstArchivedStudents2017->HRManagerTelNo->setDbValue($rs->fields('HRManagerTelNo'));
		$cstArchivedStudents2017->HRManagerCellNo->setDbValue($rs->fields('HRManagerCellNo'));
		$cstArchivedStudents2017->HRManagerEmail->setDbValue($rs->fields('HRManagerEmail'));
		$cstArchivedStudents2017->LengthEmploy->setDbValue($rs->fields('LengthEmploy'));
		$cstArchivedStudents2017->BlockAccess->setDbValue($rs->fields('BlockAccess'));
		$cstArchivedStudents2017->Archived->setDbValue($rs->fields('Archived'));
		$cstArchivedStudents2017->ResultLetter->Upload->DbValue = $rs->fields('ResultLetter');
		$cstArchivedStudents2017->Achieved->setDbValue($rs->fields('Achieved'));
		$cstArchivedStudents2017->IDFile->Upload->DbValue = $rs->fields('IDFile');
		$cstArchivedStudents2017->ReasonForLeaving->setDbValue($rs->fields('ReasonForLeaving'));
	}

	// Render row values based on field settings
	function RenderRow() {
		global $conn, $Security, $Language, $cstArchivedStudents2017;

		// Initialize URLs
		$this->ExportPrintUrl = $this->PageUrl() . "export=print&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->ExportHtmlUrl = $this->PageUrl() . "export=html&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->ExportExcelUrl = $this->PageUrl() . "export=excel&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->ExportWordUrl = $this->PageUrl() . "export=word&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->ExportXmlUrl = $this->PageUrl() . "export=xml&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->ExportCsvUrl = $this->PageUrl() . "export=csv&" . "CCEStudentID=" . urlencode($cstArchivedStudents2017->CCEStudentID->CurrentValue);
		$this->AddUrl = $cstArchivedStudents2017->AddUrl();
		$this->EditUrl = $cstArchivedStudents2017->EditUrl();
		$this->CopyUrl = $cstArchivedStudents2017->CopyUrl();
		$this->DeleteUrl = $cstArchivedStudents2017->DeleteUrl();
		$this->ListUrl = $cstArchivedStudents2017->ListUrl();

		// Call Row_Rendering event
		$cstArchivedStudents2017->Row_Rendering();

		// Common render codes for all row types
		// Title

		$cstArchivedStudents2017->Title->CellCssStyle = ""; $cstArchivedStudents2017->Title->CellCssClass = "";
		$cstArchivedStudents2017->Title->CellAttrs = array(); $cstArchivedStudents2017->Title->ViewAttrs = array(); $cstArchivedStudents2017->Title->EditAttrs = array();

		// FirstName
		$cstArchivedStudents2017->FirstName->CellCssStyle = ""; $cstArchivedStudents2017->FirstName->CellCssClass = "";
		$cstArchivedStudents2017->FirstName->CellAttrs = array(); $cstArchivedStudents2017->FirstName->ViewAttrs = array(); $cstArchivedStudents2017->FirstName->EditAttrs = array();

		// Surname
		$cstArchivedStudents2017->Surname->CellCssStyle = ""; $cstArchivedStudents2017->Surname->CellCssClass = "";
		$cstArchivedStudents2017->Surname->CellAttrs = array(); $cstArchivedStudents2017->Surname->ViewAttrs = array(); $cstArchivedStudents2017->Surname->EditAttrs = array();

		// KnownAs
		$cstArchivedStudents2017->KnownAs->CellCssStyle = ""; $cstArchivedStudents2017->KnownAs->CellCssClass = "";
		$cstArchivedStudents2017->KnownAs->CellAttrs = array(); $cstArchivedStudents2017->KnownAs->ViewAttrs = array(); $cstArchivedStudents2017->KnownAs->EditAttrs = array();

		// Organisation
		$cstArchivedStudents2017->Organisation->CellCssStyle = ""; $cstArchivedStudents2017->Organisation->CellCssClass = "";
		$cstArchivedStudents2017->Organisation->CellAttrs = array(); $cstArchivedStudents2017->Organisation->ViewAttrs = array(); $cstArchivedStudents2017->Organisation->EditAttrs = array();

		// OrganisationType
		$cstArchivedStudents2017->OrganisationType->CellCssStyle = ""; $cstArchivedStudents2017->OrganisationType->CellCssClass = "";
		$cstArchivedStudents2017->OrganisationType->CellAttrs = array(); $cstArchivedStudents2017->OrganisationType->ViewAttrs = array(); $cstArchivedStudents2017->OrganisationType->EditAttrs = array();

		// StudentNumber
		$cstArchivedStudents2017->StudentNumber->CellCssStyle = ""; $cstArchivedStudents2017->StudentNumber->CellCssClass = "";
		$cstArchivedStudents2017->StudentNumber->CellAttrs = array(); $cstArchivedStudents2017->StudentNumber->ViewAttrs = array(); $cstArchivedStudents2017->StudentNumber->EditAttrs = array();

		// CCEFacilitatorID
		$cstArchivedStudents2017->CCEFacilitatorID->CellCssStyle = ""; $cstArchivedStudents2017->CCEFacilitatorID->CellCssClass = "";
		$cstArchivedStudents2017->CCEFacilitatorID->CellAttrs = array(); $cstArchivedStudents2017->CCEFacilitatorID->ViewAttrs = array(); $cstArchivedStudents2017->CCEFacilitatorID->EditAttrs = array();

		// Project
		$cstArchivedStudents2017->Project->CellCssStyle = ""; $cstArchivedStudents2017->Project->CellCssClass = "";
		$cstArchivedStudents2017->Project->CellAttrs = array(); $cstArchivedStudents2017->Project->ViewAttrs = array(); $cstArchivedStudents2017->Project->EditAttrs = array();

		// ProjectDiscipline
		$cstArchivedStudents2017->ProjectDiscipline->CellCssStyle = ""; $cstArchivedStudents2017->ProjectDiscipline->CellCssClass = "";
		$cstArchivedStudents2017->ProjectDiscipline->CellAttrs = array(); $cstArchivedStudents2017->ProjectDiscipline->ViewAttrs = array(); $cstArchivedStudents2017->ProjectDiscipline->EditAttrs = array();

		// IDNumber
		$cstArchivedStudents2017->IDNumber->CellCssStyle = ""; $cstArchivedStudents2017->IDNumber->CellCssClass = "";
		$cstArchivedStudents2017->IDNumber->CellAttrs = array(); $cstArchivedStudents2017->IDNumber->ViewAttrs = array(); $cstArchivedStudents2017->IDNumber->EditAttrs = array();

		// ECSANumber
		$cstArchivedStudents2017->ECSANumber->CellCssStyle = ""; $cstArchivedStudents2017->ECSANumber->CellCssClass = "";
		$cstArchivedStudents2017->ECSANumber->CellAttrs = array(); $cstArchivedStudents2017->ECSANumber->ViewAttrs = array(); $cstArchivedStudents2017->ECSANumber->EditAttrs = array();

		// Age
		$cstArchivedStudents2017->Age->CellCssStyle = ""; $cstArchivedStudents2017->Age->CellCssClass = "";
		$cstArchivedStudents2017->Age->CellAttrs = array(); $cstArchivedStudents2017->Age->ViewAttrs = array(); $cstArchivedStudents2017->Age->EditAttrs = array();

		// HighestQual
		$cstArchivedStudents2017->HighestQual->CellCssStyle = ""; $cstArchivedStudents2017->HighestQual->CellCssClass = "";
		$cstArchivedStudents2017->HighestQual->CellAttrs = array(); $cstArchivedStudents2017->HighestQual->ViewAttrs = array(); $cstArchivedStudents2017->HighestQual->EditAttrs = array();

		// AreaDiscipline
		$cstArchivedStudents2017->AreaDiscipline->CellCssStyle = ""; $cstArchivedStudents2017->AreaDiscipline->CellCssClass = "";
		$cstArchivedStudents2017->AreaDiscipline->CellAttrs = array(); $cstArchivedStudents2017->AreaDiscipline->ViewAttrs = array(); $cstArchivedStudents2017->AreaDiscipline->EditAttrs = array();

		// Telephone
		$cstArchivedStudents2017->Telephone->CellCssStyle = ""; $cstArchivedStudents2017->Telephone->CellCssClass = "";
		$cstArchivedStudents2017->Telephone->CellAttrs = array(); $cstArchivedStudents2017->Telephone->ViewAttrs = array(); $cstArchivedStudents2017->Telephone->EditAttrs = array();

		// Cellphone
		$cstArchivedStudents2017->Cellphone->CellCssStyle = ""; $cstArchivedStudents2017->Cellphone->CellCssClass = "";
		$cstArchivedStudents2017->Cellphone->CellAttrs = array(); $cstArchivedStudents2017->Cellphone->ViewAttrs = array(); $cstArchivedStudents2017->Cellphone->EditAttrs = array();

		// EmailAddress
		$cstArchivedStudents2017->EmailAddress->CellCssStyle = ""; $cstArchivedStudents2017->EmailAddress->CellCssClass = "";
		$cstArchivedStudents2017->EmailAddress->CellAttrs = array(); $cstArchivedStudents2017->EmailAddress->ViewAttrs = array(); $cstArchivedStudents2017->EmailAddress->EditAttrs = array();

		// Designation
		$cstArchivedStudents2017->Designation->CellCssStyle = ""; $cstArchivedStudents2017->Designation->CellCssClass = "";
		$cstArchivedStudents2017->Designation->CellAttrs = array(); $cstArchivedStudents2017->Designation->ViewAttrs = array(); $cstArchivedStudents2017->Designation->EditAttrs = array();

		// Department
		$cstArchivedStudents2017->Department->CellCssStyle = ""; $cstArchivedStudents2017->Department->CellCssClass = "";
		$cstArchivedStudents2017->Department->CellAttrs = array(); $cstArchivedStudents2017->Department->ViewAttrs = array(); $cstArchivedStudents2017->Department->EditAttrs = array();

		// CVFile
		$cstArchivedStudents2017->CVFile->CellCssStyle = ""; $cstArchivedStudents2017->CVFile->CellCssClass = "";
		$cstArchivedStudents2017->CVFile->CellAttrs = array(); $cstArchivedStudents2017->CVFile->ViewAttrs = array(); $cstArchivedStudents2017->CVFile->EditAttrs = array();

		// QualCertificate1
		$cstArchivedStudents2017->QualCertificate1->CellCssStyle = ""; $cstArchivedStudents2017->QualCertificate1->CellCssClass = "";
		$cstArchivedStudents2017->QualCertificate1->CellAttrs = array(); $cstArchivedStudents2017->QualCertificate1->ViewAttrs = array(); $cstArchivedStudents2017->QualCertificate1->EditAttrs = array();

		// QualCertificate2
		$cstArchivedStudents2017->QualCertificate2->CellCssStyle = ""; $cstArchivedStudents2017->QualCertificate2->CellCssClass = "";
		$cstArchivedStudents2017->QualCertificate2->CellAttrs = array(); $cstArchivedStudents2017->QualCertificate2->ViewAttrs = array(); $cstArchivedStudents2017->QualCertificate2->EditAttrs = array();

		// QualCertificate3
		$cstArchivedStudents2017->QualCertificate3->CellCssStyle = ""; $cstArchivedStudents2017->QualCertificate3->CellCssClass = "";
		$cstArchivedStudents2017->QualCertificate3->CellAttrs = array(); $cstArchivedStudents2017->QualCertificate3->ViewAttrs = array(); $cstArchivedStudents2017->QualCertificate3->EditAttrs = array();

		// MemorandumFile
		$cstArchivedStudents2017->MemorandumFile->CellCssStyle = ""; $cstArchivedStudents2017->MemorandumFile->CellCssClass = "";
		$cstArchivedStudents2017->MemorandumFile->CellAttrs = array(); $cstArchivedStudents2017->MemorandumFile->ViewAttrs = array(); $cstArchivedStudents2017->MemorandumFile->EditAttrs = array();

		// AgreementFile
		$cstArchivedStudents2017->AgreementFile->CellCssStyle = ""; $cstArchivedStudents2017->AgreementFile->CellCssClass = "";
		$cstArchivedStudents2017->AgreementFile->CellAttrs = array(); $cstArchivedStudents2017->AgreementFile->ViewAttrs = array(); $cstArchivedStudents2017->AgreementFile->EditAttrs = array();

		// OrderNo
		$cstArchivedStudents2017->OrderNo->CellCssStyle = ""; $cstArchivedStudents2017->OrderNo->CellCssClass = "";
		$cstArchivedStudents2017->OrderNo->CellAttrs = array(); $cstArchivedStudents2017->OrderNo->ViewAttrs = array(); $cstArchivedStudents2017->OrderNo->EditAttrs = array();

		// WebUsername
		$cstArchivedStudents2017->WebUsername->CellCssStyle = ""; $cstArchivedStudents2017->WebUsername->CellCssClass = "";
		$cstArchivedStudents2017->WebUsername->CellAttrs = array(); $cstArchivedStudents2017->WebUsername->ViewAttrs = array(); $cstArchivedStudents2017->WebUsername->EditAttrs = array();

		// WebPassword
		$cstArchivedStudents2017->WebPassword->CellCssStyle = ""; $cstArchivedStudents2017->WebPassword->CellCssClass = "";
		$cstArchivedStudents2017->WebPassword->CellAttrs = array(); $cstArchivedStudents2017->WebPassword->ViewAttrs = array(); $cstArchivedStudents2017->WebPassword->EditAttrs = array();

		// MentorName
		$cstArchivedStudents2017->MentorName->CellCssStyle = ""; $cstArchivedStudents2017->MentorName->CellCssClass = "";
		$cstArchivedStudents2017->MentorName->CellAttrs = array(); $cstArchivedStudents2017->MentorName->ViewAttrs = array(); $cstArchivedStudents2017->MentorName->EditAttrs = array();

		// MentorDesig
		$cstArchivedStudents2017->MentorDesig->CellCssStyle = ""; $cstArchivedStudents2017->MentorDesig->CellCssClass = "";
		$cstArchivedStudents2017->MentorDesig->CellAttrs = array(); $cstArchivedStudents2017->MentorDesig->ViewAttrs = array(); $cstArchivedStudents2017->MentorDesig->EditAttrs = array();

		// MentorTel
		$cstArchivedStudents2017->MentorTel->CellCssStyle = ""; $cstArchivedStudents2017->MentorTel->CellCssClass = "";
		$cstArchivedStudents2017->MentorTel->CellAttrs = array(); $cstArchivedStudents2017->MentorTel->ViewAttrs = array(); $cstArchivedStudents2017->MentorTel->EditAttrs = array();

		// MentorCell
		$cstArchivedStudents2017->MentorCell->CellCssStyle = ""; $cstArchivedStudents2017->MentorCell->CellCssClass = "";
		$cstArchivedStudents2017->MentorCell->CellAttrs = array(); $cstArchivedStudents2017->MentorCell->ViewAttrs = array(); $cstArchivedStudents2017->MentorCell->EditAttrs = array();

		// MentorEmail
		$cstArchivedStudents2017->MentorEmail->CellCssStyle = ""; $cstArchivedStudents2017->MentorEmail->CellCssClass = "";
		$cstArchivedStudents2017->MentorEmail->CellAttrs = array(); $cstArchivedStudents2017->MentorEmail->ViewAttrs = array(); $cstArchivedStudents2017->MentorEmail->EditAttrs = array();

		// HRManagerName
		$cstArchivedStudents2017->HRManagerName->CellCssStyle = ""; $cstArchivedStudents2017->HRManagerName->CellCssClass = "";
		$cstArchivedStudents2017->HRManagerName->CellAttrs = array(); $cstArchivedStudents2017->HRManagerName->ViewAttrs = array(); $cstArchivedStudents2017->HRManagerName->EditAttrs = array();

		// HRManagerDesignation
		$cstArchivedStudents2017->HRManagerDesignation->CellCssStyle = ""; $cstArchivedStudents2017->HRManagerDesignation->CellCssClass = "";
		$cstArchivedStudents2017->HRManagerDesignation->CellAttrs = array(); $cstArchivedStudents2017->HRManagerDesignation->ViewAttrs = array(); $cstArchivedStudents2017->HRManagerDesignation->EditAttrs = array();

		// HRManagerTelNo
		$cstArchivedStudents2017->HRManagerTelNo->CellCssStyle = ""; $cstArchivedStudents2017->HRManagerTelNo->CellCssClass = "";
		$cstArchivedStudents2017->HRManagerTelNo->CellAttrs = array(); $cstArchivedStudents2017->HRManagerTelNo->ViewAttrs = array(); $cstArchivedStudents2017->HRManagerTelNo->EditAttrs = array();

		// HRManagerCellNo
		$cstArchivedStudents2017->HRManagerCellNo->CellCssStyle = ""; $cstArchivedStudents2017->HRManagerCellNo->CellCssClass = "";
		$cstArchivedStudents2017->HRManagerCellNo->CellAttrs = array(); $cstArchivedStudents2017->HRManagerCellNo->ViewAttrs = array(); $cstArchivedStudents2017->HRManagerCellNo->EditAttrs = array();

		// HRManagerEmail
		$cstArchivedStudents2017->HRManagerEmail->CellCssStyle = ""; $cstArchivedStudents2017->HRManagerEmail->CellCssClass = "";
		$cstArchivedStudents2017->HRManagerEmail->CellAttrs = array(); $cstArchivedStudents2017->HRManagerEmail->ViewAttrs = array(); $cstArchivedStudents2017->HRManagerEmail->EditAttrs = array();

		// LengthEmploy
		$cstArchivedStudents2017->LengthEmploy->CellCssStyle = ""; $cstArchivedStudents2017->LengthEmploy->CellCssClass = "";
		$cstArchivedStudents2017->LengthEmploy->CellAttrs = array(); $cstArchivedStudents2017->LengthEmploy->ViewAttrs = array(); $cstArchivedStudents2017->LengthEmploy->EditAttrs = array();

		// ResultLetter
		$cstArchivedStudents2017->ResultLetter->CellCssStyle = ""; $cstArchivedStudents2017->ResultLetter->CellCssClass = "";
		$cstArchivedStudents2017->ResultLetter->CellAttrs = array(); $cstArchivedStudents2017->ResultLetter->ViewAttrs = array(); $cstArchivedStudents2017->ResultLetter->EditAttrs = array();

		// IDFile
		$cstArchivedStudents2017->IDFile->CellCssStyle = ""; $cstArchivedStudents2017->IDFile->CellCssClass = "";
		$cstArchivedStudents2017->IDFile->CellAttrs = array(); $cstArchivedStudents2017->IDFile->ViewAttrs = array(); $cstArchivedStudents2017->IDFile->EditAttrs = array();

		// ReasonForLeaving
		$cstArchivedStudents2017->ReasonForLeaving->CellCssStyle = ""; $cstArchivedStudents2017->ReasonForLeaving->CellCssClass = "";
		$cstArchivedStudents2017->ReasonForLeaving->CellAttrs = array(); $cstArchivedStudents2017->ReasonForLeaving->ViewAttrs = array(); $cstArchivedStudents2017->ReasonForLeaving->EditAttrs = array();
		if ($cstArchivedStudents2017->RowType == EW_ROWTYPE_VIEW) { // View row

			// Title
			$cstArchivedStudents2017->Title->ViewValue = $cstArchivedStudents2017->Title->CurrentValue;
			$cstArchivedStudents2017->Title->CssStyle = "";
			$cstArchivedStudents2017->Title->CssClass = "";
			$cstArchivedStudents2017->Title->ViewCustomAttributes = "";

			// FirstName
			$cstArchivedStudents2017->FirstName->ViewValue = $cstArchivedStudents2017->FirstName->CurrentValue;
			$cstArchivedStudents2017->FirstName->CssStyle = "";
			$cstArchivedStudents2017->FirstName->CssClass = "";
			$cstArchivedStudents2017->FirstName->ViewCustomAttributes = "";

			// Surname
			$cstArchivedStudents2017->Surname->ViewValue = $cstArchivedStudents2017->Surname->CurrentValue;
			$cstArchivedStudents2017->Surname->CssStyle = "";
			$cstArchivedStudents2017->Surname->CssClass = "";
			$cstArchivedStudents2017->Surname->ViewCustomAttributes = "";

			// KnownAs
			$cstArchivedStudents2017->KnownAs->ViewValue = $cstArchivedStudents2017->KnownAs->CurrentValue;
			$cstArchivedStudents2017->KnownAs->CssStyle = "";
			$cstArchivedStudents2017->KnownAs->CssClass = "";
			$cstArchivedStudents2017->KnownAs->ViewCustomAttributes = "";

			// Organisation
			$cstArchivedStudents2017->Organisation->ViewValue = $cstArchivedStudents2017->Organisation->CurrentValue;
			$cstArchivedStudents2017->Organisation->CssStyle = "";
			$cstArchivedStudents2017->Organisation->CssClass = "";
			$cstArchivedStudents2017->Organisation->ViewCustomAttributes = "";

			// OrganisationType
			$cstArchivedStudents2017->OrganisationType->ViewValue = $cstArchivedStudents2017->OrganisationType->CurrentValue;
			$cstArchivedStudents2017->OrganisationType->CssStyle = "";
			$cstArchivedStudents2017->OrganisationType->CssClass = "";
			$cstArchivedStudents2017->OrganisationType->ViewCustomAttributes = "";

			// StudentNumber
			$cstArchivedStudents2017->StudentNumber->ViewValue = $cstArchivedStudents2017->StudentNumber->CurrentValue;
			$cstArchivedStudents2017->StudentNumber->CssStyle = "";
			$cstArchivedStudents2017->StudentNumber->CssClass = "";
			$cstArchivedStudents2017->StudentNumber->ViewCustomAttributes = "";

			// CCEFacilitatorID
			$cstArchivedStudents2017->CCEFacilitatorID->ViewValue = $cstArchivedStudents2017->CCEFacilitatorID->CurrentValue;
			$cstArchivedStudents2017->CCEFacilitatorID->CssStyle = "";
			$cstArchivedStudents2017->CCEFacilitatorID->CssClass = "";
			$cstArchivedStudents2017->CCEFacilitatorID->ViewCustomAttributes = "";

			// Project
			$cstArchivedStudents2017->Project->ViewValue = $cstArchivedStudents2017->Project->CurrentValue;
			$cstArchivedStudents2017->Project->CssStyle = "";
			$cstArchivedStudents2017->Project->CssClass = "";
			$cstArchivedStudents2017->Project->ViewCustomAttributes = "";

			// ProjectDiscipline
			$cstArchivedStudents2017->ProjectDiscipline->ViewValue = $cstArchivedStudents2017->ProjectDiscipline->CurrentValue;
			$cstArchivedStudents2017->ProjectDiscipline->CssStyle = "";
			$cstArchivedStudents2017->ProjectDiscipline->CssClass = "";
			$cstArchivedStudents2017->ProjectDiscipline->ViewCustomAttributes = "";

			// IDNumber
			$cstArchivedStudents2017->IDNumber->ViewValue = $cstArchivedStudents2017->IDNumber->CurrentValue;
			$cstArchivedStudents2017->IDNumber->CssStyle = "";
			$cstArchivedStudents2017->IDNumber->CssClass = "";
			$cstArchivedStudents2017->IDNumber->ViewCustomAttributes = "";

			// ECSANumber
			$cstArchivedStudents2017->ECSANumber->ViewValue = $cstArchivedStudents2017->ECSANumber->CurrentValue;
			$cstArchivedStudents2017->ECSANumber->CssStyle = "";
			$cstArchivedStudents2017->ECSANumber->CssClass = "";
			$cstArchivedStudents2017->ECSANumber->ViewCustomAttributes = "";

			// Age
			$cstArchivedStudents2017->Age->ViewValue = $cstArchivedStudents2017->Age->CurrentValue;
			$cstArchivedStudents2017->Age->CssStyle = "";
			$cstArchivedStudents2017->Age->CssClass = "";
			$cstArchivedStudents2017->Age->ViewCustomAttributes = "";

			// HighestQual
			$cstArchivedStudents2017->HighestQual->ViewValue = $cstArchivedStudents2017->HighestQual->CurrentValue;
			$cstArchivedStudents2017->HighestQual->CssStyle = "";
			$cstArchivedStudents2017->HighestQual->CssClass = "";
			$cstArchivedStudents2017->HighestQual->ViewCustomAttributes = "";

			// AreaDiscipline
			$cstArchivedStudents2017->AreaDiscipline->ViewValue = $cstArchivedStudents2017->AreaDiscipline->CurrentValue;
			$cstArchivedStudents2017->AreaDiscipline->CssStyle = "";
			$cstArchivedStudents2017->AreaDiscipline->CssClass = "";
			$cstArchivedStudents2017->AreaDiscipline->ViewCustomAttributes = "";

			// Telephone
			$cstArchivedStudents2017->Telephone->ViewValue = $cstArchivedStudents2017->Telephone->CurrentValue;
			$cstArchivedStudents2017->Telephone->CssStyle = "";
			$cstArchivedStudents2017->Telephone->CssClass = "";
			$cstArchivedStudents2017->Telephone->ViewCustomAttributes = "";

			// Cellphone
			$cstArchivedStudents2017->Cellphone->ViewValue = $cstArchivedStudents2017->Cellphone->CurrentValue;
			$cstArchivedStudents2017->Cellphone->CssStyle = "";
			$cstArchivedStudents2017->Cellphone->CssClass = "";
			$cstArchivedStudents2017->Cellphone->ViewCustomAttributes = "";

			// EmailAddress
			$cstArchivedStudents2017->EmailAddress->ViewValue = $cstArchivedStudents2017->EmailAddress->CurrentValue;
			$cstArchivedStudents2017->EmailAddress->CssStyle = "";
			$cstArchivedStudents2017->EmailAddress->CssClass = "";
			$cstArchivedStudents2017->EmailAddress->ViewCustomAttributes = "";

			// HomeAddress
			$cstArchivedStudents2017->HomeAddress->ViewValue = $cstArchivedStudents2017->HomeAddress->CurrentValue;
			$cstArchivedStudents2017->HomeAddress->CssStyle = "";
			$cstArchivedStudents2017->HomeAddress->CssClass = "";
			$cstArchivedStudents2017->HomeAddress->ViewCustomAttributes = "";

			// WorkAddress
			$cstArchivedStudents2017->WorkAddress->ViewValue = $cstArchivedStudents2017->WorkAddress->CurrentValue;
			$cstArchivedStudents2017->WorkAddress->CssStyle = "";
			$cstArchivedStudents2017->WorkAddress->CssClass = "";
			$cstArchivedStudents2017->WorkAddress->ViewCustomAttributes = "";

			// PostalAddress
			$cstArchivedStudents2017->PostalAddress->ViewValue = $cstArchivedStudents2017->PostalAddress->CurrentValue;
			$cstArchivedStudents2017->PostalAddress->CssStyle = "";
			$cstArchivedStudents2017->PostalAddress->CssClass = "";
			$cstArchivedStudents2017->PostalAddress->ViewCustomAttributes = "";

			// Designation
			$cstArchivedStudents2017->Designation->ViewValue = $cstArchivedStudents2017->Designation->CurrentValue;
			$cstArchivedStudents2017->Designation->CssStyle = "";
			$cstArchivedStudents2017->Designation->CssClass = "";
			$cstArchivedStudents2017->Designation->ViewCustomAttributes = "";

			// Department
			$cstArchivedStudents2017->Department->ViewValue = $cstArchivedStudents2017->Department->CurrentValue;
			$cstArchivedStudents2017->Department->CssStyle = "";
			$cstArchivedStudents2017->Department->CssClass = "";
			$cstArchivedStudents2017->Department->ViewCustomAttributes = "";

			// CESAAccountNo
			$cstArchivedStudents2017->CESAAccountNo->ViewValue = $cstArchivedStudents2017->CESAAccountNo->CurrentValue;
			$cstArchivedStudents2017->CESAAccountNo->CssStyle = "";
			$cstArchivedStudents2017->CESAAccountNo->CssClass = "";
			$cstArchivedStudents2017->CESAAccountNo->ViewCustomAttributes = "";

			// VATNo
			$cstArchivedStudents2017->VATNo->ViewValue = $cstArchivedStudents2017->VATNo->CurrentValue;
			$cstArchivedStudents2017->VATNo->CssStyle = "";
			$cstArchivedStudents2017->VATNo->CssClass = "";
			$cstArchivedStudents2017->VATNo->ViewCustomAttributes = "";

			// DietaryRequirements
			$cstArchivedStudents2017->DietaryRequirements->ViewValue = $cstArchivedStudents2017->DietaryRequirements->CurrentValue;
			$cstArchivedStudents2017->DietaryRequirements->CssStyle = "";
			$cstArchivedStudents2017->DietaryRequirements->CssClass = "";
			$cstArchivedStudents2017->DietaryRequirements->ViewCustomAttributes = "";

			// CVFile
			if (!ew_Empty($cstArchivedStudents2017->CVFile->Upload->DbValue)) {
				$cstArchivedStudents2017->CVFile->ViewValue = $cstArchivedStudents2017->CVFile->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->CVFile->ViewValue = "";
			}
			$cstArchivedStudents2017->CVFile->CssStyle = "";
			$cstArchivedStudents2017->CVFile->CssClass = "";
			$cstArchivedStudents2017->CVFile->ViewCustomAttributes = "";

			// QualCertificate1
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate1->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate1->ViewValue = $cstArchivedStudents2017->QualCertificate1->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->QualCertificate1->ViewValue = "";
			}
			$cstArchivedStudents2017->QualCertificate1->CssStyle = "";
			$cstArchivedStudents2017->QualCertificate1->CssClass = "";
			$cstArchivedStudents2017->QualCertificate1->ViewCustomAttributes = "";

			// QualCertificate2
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate2->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate2->ViewValue = $cstArchivedStudents2017->QualCertificate2->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->QualCertificate2->ViewValue = "";
			}
			$cstArchivedStudents2017->QualCertificate2->CssStyle = "";
			$cstArchivedStudents2017->QualCertificate2->CssClass = "";
			$cstArchivedStudents2017->QualCertificate2->ViewCustomAttributes = "";

			// QualCertificate3
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate3->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate3->ViewValue = $cstArchivedStudents2017->QualCertificate3->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->QualCertificate3->ViewValue = "";
			}
			$cstArchivedStudents2017->QualCertificate3->CssStyle = "";
			$cstArchivedStudents2017->QualCertificate3->CssClass = "";
			$cstArchivedStudents2017->QualCertificate3->ViewCustomAttributes = "";

			// MemorandumFile
			if (!ew_Empty($cstArchivedStudents2017->MemorandumFile->Upload->DbValue)) {
				$cstArchivedStudents2017->MemorandumFile->ViewValue = $cstArchivedStudents2017->MemorandumFile->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->MemorandumFile->ViewValue = "";
			}
			$cstArchivedStudents2017->MemorandumFile->CssStyle = "";
			$cstArchivedStudents2017->MemorandumFile->CssClass = "";
			$cstArchivedStudents2017->MemorandumFile->ViewCustomAttributes = "";

			// AgreementFile
			if (!ew_Empty($cstArchivedStudents2017->AgreementFile->Upload->DbValue)) {
				$cstArchivedStudents2017->AgreementFile->ViewValue = $cstArchivedStudents2017->AgreementFile->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->AgreementFile->ViewValue = "";
			}
			$cstArchivedStudents2017->AgreementFile->CssStyle = "";
			$cstArchivedStudents2017->AgreementFile->CssClass = "";
			$cstArchivedStudents2017->AgreementFile->ViewCustomAttributes = "";

			// OrderNo
			$cstArchivedStudents2017->OrderNo->ViewValue = $cstArchivedStudents2017->OrderNo->CurrentValue;
			$cstArchivedStudents2017->OrderNo->CssStyle = "";
			$cstArchivedStudents2017->OrderNo->CssClass = "";
			$cstArchivedStudents2017->OrderNo->ViewCustomAttributes = "";

			// BookedByName
			$cstArchivedStudents2017->BookedByName->ViewValue = $cstArchivedStudents2017->BookedByName->CurrentValue;
			$cstArchivedStudents2017->BookedByName->CssStyle = "";
			$cstArchivedStudents2017->BookedByName->CssClass = "";
			$cstArchivedStudents2017->BookedByName->ViewCustomAttributes = "";

			// BookedByDesignation
			$cstArchivedStudents2017->BookedByDesignation->ViewValue = $cstArchivedStudents2017->BookedByDesignation->CurrentValue;
			$cstArchivedStudents2017->BookedByDesignation->CssStyle = "";
			$cstArchivedStudents2017->BookedByDesignation->CssClass = "";
			$cstArchivedStudents2017->BookedByDesignation->ViewCustomAttributes = "";

			// BookedByTelNo
			$cstArchivedStudents2017->BookedByTelNo->ViewValue = $cstArchivedStudents2017->BookedByTelNo->CurrentValue;
			$cstArchivedStudents2017->BookedByTelNo->CssStyle = "";
			$cstArchivedStudents2017->BookedByTelNo->CssClass = "";
			$cstArchivedStudents2017->BookedByTelNo->ViewCustomAttributes = "";

			// BookedByFaxNo
			$cstArchivedStudents2017->BookedByFaxNo->ViewValue = $cstArchivedStudents2017->BookedByFaxNo->CurrentValue;
			$cstArchivedStudents2017->BookedByFaxNo->CssStyle = "";
			$cstArchivedStudents2017->BookedByFaxNo->CssClass = "";
			$cstArchivedStudents2017->BookedByFaxNo->ViewCustomAttributes = "";

			// BookedByCellNo
			$cstArchivedStudents2017->BookedByCellNo->ViewValue = $cstArchivedStudents2017->BookedByCellNo->CurrentValue;
			$cstArchivedStudents2017->BookedByCellNo->CssStyle = "";
			$cstArchivedStudents2017->BookedByCellNo->CssClass = "";
			$cstArchivedStudents2017->BookedByCellNo->ViewCustomAttributes = "";

			// BookedByEmail
			$cstArchivedStudents2017->BookedByEmail->ViewValue = $cstArchivedStudents2017->BookedByEmail->CurrentValue;
			$cstArchivedStudents2017->BookedByEmail->CssStyle = "";
			$cstArchivedStudents2017->BookedByEmail->CssClass = "";
			$cstArchivedStudents2017->BookedByEmail->ViewCustomAttributes = "";

			// WebUsername
			$cstArchivedStudents2017->WebUsername->ViewValue = $cstArchivedStudents2017->WebUsername->CurrentValue;
			$cstArchivedStudents2017->WebUsername->CssStyle = "";
			$cstArchivedStudents2017->WebUsername->CssClass = "";
			$cstArchivedStudents2017->WebUsername->ViewCustomAttributes = "";

			// WebPassword
			$cstArchivedStudents2017->WebPassword->ViewValue = $cstArchivedStudents2017->WebPassword->CurrentValue;
			$cstArchivedStudents2017->WebPassword->CssStyle = "";
			$cstArchivedStudents2017->WebPassword->CssClass = "";
			$cstArchivedStudents2017->WebPassword->ViewCustomAttributes = "";

			// MentorName
			$cstArchivedStudents2017->MentorName->ViewValue = $cstArchivedStudents2017->MentorName->CurrentValue;
			$cstArchivedStudents2017->MentorName->CssStyle = "";
			$cstArchivedStudents2017->MentorName->CssClass = "";
			$cstArchivedStudents2017->MentorName->ViewCustomAttributes = "";

			// MentorDesig
			$cstArchivedStudents2017->MentorDesig->ViewValue = $cstArchivedStudents2017->MentorDesig->CurrentValue;
			$cstArchivedStudents2017->MentorDesig->CssStyle = "";
			$cstArchivedStudents2017->MentorDesig->CssClass = "";
			$cstArchivedStudents2017->MentorDesig->ViewCustomAttributes = "";

			// MentorTel
			$cstArchivedStudents2017->MentorTel->ViewValue = $cstArchivedStudents2017->MentorTel->CurrentValue;
			$cstArchivedStudents2017->MentorTel->CssStyle = "";
			$cstArchivedStudents2017->MentorTel->CssClass = "";
			$cstArchivedStudents2017->MentorTel->ViewCustomAttributes = "";

			// MentorCell
			$cstArchivedStudents2017->MentorCell->ViewValue = $cstArchivedStudents2017->MentorCell->CurrentValue;
			$cstArchivedStudents2017->MentorCell->CssStyle = "";
			$cstArchivedStudents2017->MentorCell->CssClass = "";
			$cstArchivedStudents2017->MentorCell->ViewCustomAttributes = "";

			// MentorEmail
			$cstArchivedStudents2017->MentorEmail->ViewValue = $cstArchivedStudents2017->MentorEmail->CurrentValue;
			$cstArchivedStudents2017->MentorEmail->CssStyle = "";
			$cstArchivedStudents2017->MentorEmail->CssClass = "";
			$cstArchivedStudents2017->MentorEmail->ViewCustomAttributes = "";

			// HRManagerName
			$cstArchivedStudents2017->HRManagerName->ViewValue = $cstArchivedStudents2017->HRManagerName->CurrentValue;
			$cstArchivedStudents2017->HRManagerName->CssStyle = "";
			$cstArchivedStudents2017->HRManagerName->CssClass = "";
			$cstArchivedStudents2017->HRManagerName->ViewCustomAttributes = "";

			// HRManagerDesignation
			$cstArchivedStudents2017->HRManagerDesignation->ViewValue = $cstArchivedStudents2017->HRManagerDesignation->CurrentValue;
			$cstArchivedStudents2017->HRManagerDesignation->CssStyle = "";
			$cstArchivedStudents2017->HRManagerDesignation->CssClass = "";
			$cstArchivedStudents2017->HRManagerDesignation->ViewCustomAttributes = "";

			// HRManagerTelNo
			$cstArchivedStudents2017->HRManagerTelNo->ViewValue = $cstArchivedStudents2017->HRManagerTelNo->CurrentValue;
			$cstArchivedStudents2017->HRManagerTelNo->CssStyle = "";
			$cstArchivedStudents2017->HRManagerTelNo->CssClass = "";
			$cstArchivedStudents2017->HRManagerTelNo->ViewCustomAttributes = "";

			// HRManagerCellNo
			$cstArchivedStudents2017->HRManagerCellNo->ViewValue = $cstArchivedStudents2017->HRManagerCellNo->CurrentValue;
			$cstArchivedStudents2017->HRManagerCellNo->CssStyle = "";
			$cstArchivedStudents2017->HRManagerCellNo->CssClass = "";
			$cstArchivedStudents2017->HRManagerCellNo->ViewCustomAttributes = "";

			// HRManagerEmail
			$cstArchivedStudents2017->HRManagerEmail->ViewValue = $cstArchivedStudents2017->HRManagerEmail->CurrentValue;
			$cstArchivedStudents2017->HRManagerEmail->CssStyle = "";
			$cstArchivedStudents2017->HRManagerEmail->CssClass = "";
			$cstArchivedStudents2017->HRManagerEmail->ViewCustomAttributes = "";

			// LengthEmploy
			$cstArchivedStudents2017->LengthEmploy->ViewValue = $cstArchivedStudents2017->LengthEmploy->CurrentValue;
			$cstArchivedStudents2017->LengthEmploy->CssStyle = "";
			$cstArchivedStudents2017->LengthEmploy->CssClass = "";
			$cstArchivedStudents2017->LengthEmploy->ViewCustomAttributes = "";

			// BlockAccess
			if (strval($cstArchivedStudents2017->BlockAccess->CurrentValue) <> "") {
				switch ($cstArchivedStudents2017->BlockAccess->CurrentValue) {
					case "y":
						$cstArchivedStudents2017->BlockAccess->ViewValue = "Yes";
						break;
					case "n":
						$cstArchivedStudents2017->BlockAccess->ViewValue = "No";
						break;
					default:
						$cstArchivedStudents2017->BlockAccess->ViewValue = $cstArchivedStudents2017->BlockAccess->CurrentValue;
				}
			} else {
				$cstArchivedStudents2017->BlockAccess->ViewValue = NULL;
			}
			$cstArchivedStudents2017->BlockAccess->CssStyle = "";
			$cstArchivedStudents2017->BlockAccess->CssClass = "";
			$cstArchivedStudents2017->BlockAccess->ViewCustomAttributes = "";

			// Archived
			if (strval($cstArchivedStudents2017->Archived->CurrentValue) <> "") {
				switch ($cstArchivedStudents2017->Archived->CurrentValue) {
					case "1":
						$cstArchivedStudents2017->Archived->ViewValue = "Yes";
						break;
					case "0":
						$cstArchivedStudents2017->Archived->ViewValue = "No";
						break;
					default:
						$cstArchivedStudents2017->Archived->ViewValue = $cstArchivedStudents2017->Archived->CurrentValue;
				}
			} else {
				$cstArchivedStudents2017->Archived->ViewValue = NULL;
			}
			$cstArchivedStudents2017->Archived->CssStyle = "";
			$cstArchivedStudents2017->Archived->CssClass = "";
			$cstArchivedStudents2017->Archived->ViewCustomAttributes = "";

			// ResultLetter
			if (!ew_Empty($cstArchivedStudents2017->ResultLetter->Upload->DbValue)) {
				$cstArchivedStudents2017->ResultLetter->ViewValue = $cstArchivedStudents2017->ResultLetter->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->ResultLetter->ViewValue = "";
			}
			$cstArchivedStudents2017->ResultLetter->CssStyle = "";
			$cstArchivedStudents2017->ResultLetter->CssClass = "";
			$cstArchivedStudents2017->ResultLetter->ViewCustomAttributes = "";

			// Achieved
			if (strval($cstArchivedStudents2017->Achieved->CurrentValue) <> "") {
				$cstArchivedStudents2017->Achieved->ViewValue = "";
				$arwrk = explode(",", strval($cstArchivedStudents2017->Achieved->CurrentValue));
				for ($ari = 0; $ari < count($arwrk); $ari++) {
					switch (trim($arwrk[$ari])) {
						case "1":
							$cstArchivedStudents2017->Achieved->ViewValue .= "Yes";
							break;
						default:
							$cstArchivedStudents2017->Achieved->ViewValue .= trim($arwrk[$ari]);
					}
					if ($ari < count($arwrk)-1) $cstArchivedStudents2017->Achieved->ViewValue .= ew_ViewOptionSeparator($ari);
				}
			} else {
				$cstArchivedStudents2017->Achieved->ViewValue = NULL;
			}
			$cstArchivedStudents2017->Achieved->CssStyle = "";
			$cstArchivedStudents2017->Achieved->CssClass = "";
			$cstArchivedStudents2017->Achieved->ViewCustomAttributes = "";

			// IDFile
			if (!ew_Empty($cstArchivedStudents2017->IDFile->Upload->DbValue)) {
				$cstArchivedStudents2017->IDFile->ViewValue = $cstArchivedStudents2017->IDFile->Upload->DbValue;
			} else {
				$cstArchivedStudents2017->IDFile->ViewValue = "";
			}
			$cstArchivedStudents2017->IDFile->CssStyle = "";
			$cstArchivedStudents2017->IDFile->CssClass = "";
			$cstArchivedStudents2017->IDFile->ViewCustomAttributes = "";

			// ReasonForLeaving
			$cstArchivedStudents2017->ReasonForLeaving->ViewValue = $cstArchivedStudents2017->ReasonForLeaving->CurrentValue;
			$cstArchivedStudents2017->ReasonForLeaving->CssStyle = "";
			$cstArchivedStudents2017->ReasonForLeaving->CssClass = "";
			$cstArchivedStudents2017->ReasonForLeaving->ViewCustomAttributes = "";

			// Title
			$cstArchivedStudents2017->Title->HrefValue = "";
			$cstArchivedStudents2017->Title->TooltipValue = "";

			// FirstName
			$cstArchivedStudents2017->FirstName->HrefValue = "";
			$cstArchivedStudents2017->FirstName->TooltipValue = "";

			// Surname
			$cstArchivedStudents2017->Surname->HrefValue = "";
			$cstArchivedStudents2017->Surname->TooltipValue = "";

			// KnownAs
			$cstArchivedStudents2017->KnownAs->HrefValue = "";
			$cstArchivedStudents2017->KnownAs->TooltipValue = "";

			// Organisation
			$cstArchivedStudents2017->Organisation->HrefValue = "";
			$cstArchivedStudents2017->Organisation->TooltipValue = "";

			// OrganisationType
			$cstArchivedStudents2017->OrganisationType->HrefValue = "";
			$cstArchivedStudents2017->OrganisationType->TooltipValue = "";

			// StudentNumber
			$cstArchivedStudents2017->StudentNumber->HrefValue = "";
			$cstArchivedStudents2017->StudentNumber->TooltipValue = "";

			// CCEFacilitatorID
			$cstArchivedStudents2017->CCEFacilitatorID->HrefValue = "";
			$cstArchivedStudents2017->CCEFacilitatorID->TooltipValue = "";

			// Project
			$cstArchivedStudents2017->Project->HrefValue = "";
			$cstArchivedStudents2017->Project->TooltipValue = "";

			// ProjectDiscipline
			$cstArchivedStudents2017->ProjectDiscipline->HrefValue = "";
			$cstArchivedStudents2017->ProjectDiscipline->TooltipValue = "";

			// IDNumber
			$cstArchivedStudents2017->IDNumber->HrefValue = "";
			$cstArchivedStudents2017->IDNumber->TooltipValue = "";

			// ECSANumber
			$cstArchivedStudents2017->ECSANumber->HrefValue = "";
			$cstArchivedStudents2017->ECSANumber->TooltipValue = "";

			// Age
			$cstArchivedStudents2017->Age->HrefValue = "";
			$cstArchivedStudents2017->Age->TooltipValue = "";

			// HighestQual
			$cstArchivedStudents2017->HighestQual->HrefValue = "";
			$cstArchivedStudents2017->HighestQual->TooltipValue = "";

			// AreaDiscipline
			$cstArchivedStudents2017->AreaDiscipline->HrefValue = "";
			$cstArchivedStudents2017->AreaDiscipline->TooltipValue = "";

			// Telephone
			$cstArchivedStudents2017->Telephone->HrefValue = "";
			$cstArchivedStudents2017->Telephone->TooltipValue = "";

			// Cellphone
			$cstArchivedStudents2017->Cellphone->HrefValue = "";
			$cstArchivedStudents2017->Cellphone->TooltipValue = "";

			// EmailAddress
			$cstArchivedStudents2017->EmailAddress->HrefValue = "";
			$cstArchivedStudents2017->EmailAddress->TooltipValue = "";

			// Designation
			$cstArchivedStudents2017->Designation->HrefValue = "";
			$cstArchivedStudents2017->Designation->TooltipValue = "";

			// Department
			$cstArchivedStudents2017->Department->HrefValue = "";
			$cstArchivedStudents2017->Department->TooltipValue = "";

			// CVFile
			if (!ew_Empty($cstArchivedStudents2017->CVFile->Upload->DbValue)) {
				$cstArchivedStudents2017->CVFile->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->CVFile->UploadPath) . ((!empty($cstArchivedStudents2017->CVFile->ViewValue)) ? $cstArchivedStudents2017->CVFile->ViewValue : $cstArchivedStudents2017->CVFile->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->CVFile->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->CVFile->HrefValue);
			} else {
				$cstArchivedStudents2017->CVFile->HrefValue = "";
			}
			$cstArchivedStudents2017->CVFile->TooltipValue = "";

			// QualCertificate1
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate1->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate1->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->QualCertificate1->UploadPath) . ((!empty($cstArchivedStudents2017->QualCertificate1->ViewValue)) ? $cstArchivedStudents2017->QualCertificate1->ViewValue : $cstArchivedStudents2017->QualCertificate1->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->QualCertificate1->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->QualCertificate1->HrefValue);
			} else {
				$cstArchivedStudents2017->QualCertificate1->HrefValue = "";
			}
			$cstArchivedStudents2017->QualCertificate1->TooltipValue = "";

			// QualCertificate2
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate2->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate2->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->QualCertificate2->UploadPath) . ((!empty($cstArchivedStudents2017->QualCertificate2->ViewValue)) ? $cstArchivedStudents2017->QualCertificate2->ViewValue : $cstArchivedStudents2017->QualCertificate2->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->QualCertificate2->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->QualCertificate2->HrefValue);
			} else {
				$cstArchivedStudents2017->QualCertificate2->HrefValue = "";
			}
			$cstArchivedStudents2017->QualCertificate2->TooltipValue = "";

			// QualCertificate3
			if (!ew_Empty($cstArchivedStudents2017->QualCertificate3->Upload->DbValue)) {
				$cstArchivedStudents2017->QualCertificate3->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->QualCertificate3->UploadPath) . ((!empty($cstArchivedStudents2017->QualCertificate3->ViewValue)) ? $cstArchivedStudents2017->QualCertificate3->ViewValue : $cstArchivedStudents2017->QualCertificate3->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->QualCertificate3->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->QualCertificate3->HrefValue);
			} else {
				$cstArchivedStudents2017->QualCertificate3->HrefValue = "";
			}
			$cstArchivedStudents2017->QualCertificate3->TooltipValue = "";

			// MemorandumFile
			if (!ew_Empty($cstArchivedStudents2017->MemorandumFile->Upload->DbValue)) {
				$cstArchivedStudents2017->MemorandumFile->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->MemorandumFile->UploadPath) . ((!empty($cstArchivedStudents2017->MemorandumFile->ViewValue)) ? $cstArchivedStudents2017->MemorandumFile->ViewValue : $cstArchivedStudents2017->MemorandumFile->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->MemorandumFile->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->MemorandumFile->HrefValue);
			} else {
				$cstArchivedStudents2017->MemorandumFile->HrefValue = "";
			}
			$cstArchivedStudents2017->MemorandumFile->TooltipValue = "";

			// AgreementFile
			if (!ew_Empty($cstArchivedStudents2017->AgreementFile->Upload->DbValue)) {
				$cstArchivedStudents2017->AgreementFile->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->AgreementFile->UploadPath) . ((!empty($cstArchivedStudents2017->AgreementFile->ViewValue)) ? $cstArchivedStudents2017->AgreementFile->ViewValue : $cstArchivedStudents2017->AgreementFile->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->AgreementFile->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->AgreementFile->HrefValue);
			} else {
				$cstArchivedStudents2017->AgreementFile->HrefValue = "";
			}
			$cstArchivedStudents2017->AgreementFile->TooltipValue = "";

			// OrderNo
			$cstArchivedStudents2017->OrderNo->HrefValue = "";
			$cstArchivedStudents2017->OrderNo->TooltipValue = "";

			// WebUsername
			$cstArchivedStudents2017->WebUsername->HrefValue = "";
			$cstArchivedStudents2017->WebUsername->TooltipValue = "";

			// WebPassword
			$cstArchivedStudents2017->WebPassword->HrefValue = "";
			$cstArchivedStudents2017->WebPassword->TooltipValue = "";

			// MentorName
			$cstArchivedStudents2017->MentorName->HrefValue = "";
			$cstArchivedStudents2017->MentorName->TooltipValue = "";

			// MentorDesig
			$cstArchivedStudents2017->MentorDesig->HrefValue = "";
			$cstArchivedStudents2017->MentorDesig->TooltipValue = "";

			// MentorTel
			$cstArchivedStudents2017->MentorTel->HrefValue = "";
			$cstArchivedStudents2017->MentorTel->TooltipValue = "";

			// MentorCell
			$cstArchivedStudents2017->MentorCell->HrefValue = "";
			$cstArchivedStudents2017->MentorCell->TooltipValue = "";

			// MentorEmail
			$cstArchivedStudents2017->MentorEmail->HrefValue = "";
			$cstArchivedStudents2017->MentorEmail->TooltipValue = "";

			// HRManagerName
			$cstArchivedStudents2017->HRManagerName->HrefValue = "";
			$cstArchivedStudents2017->HRManagerName->TooltipValue = "";

			// HRManagerDesignation
			$cstArchivedStudents2017->HRManagerDesignation->HrefValue = "";
			$cstArchivedStudents2017->HRManagerDesignation->TooltipValue = "";

			// HRManagerTelNo
			$cstArchivedStudents2017->HRManagerTelNo->HrefValue = "";
			$cstArchivedStudents2017->HRManagerTelNo->TooltipValue = "";

			// HRManagerCellNo
			$cstArchivedStudents2017->HRManagerCellNo->HrefValue = "";
			$cstArchivedStudents2017->HRManagerCellNo->TooltipValue = "";

			// HRManagerEmail
			$cstArchivedStudents2017->HRManagerEmail->HrefValue = "";
			$cstArchivedStudents2017->HRManagerEmail->TooltipValue = "";

			// LengthEmploy
			$cstArchivedStudents2017->LengthEmploy->HrefValue = "";
			$cstArchivedStudents2017->LengthEmploy->TooltipValue = "";

			// ResultLetter
			if (!ew_Empty($cstArchivedStudents2017->ResultLetter->Upload->DbValue)) {
				$cstArchivedStudents2017->ResultLetter->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->ResultLetter->UploadPath) . ((!empty($cstArchivedStudents2017->ResultLetter->ViewValue)) ? $cstArchivedStudents2017->ResultLetter->ViewValue : $cstArchivedStudents2017->ResultLetter->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->ResultLetter->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->ResultLetter->HrefValue);
			} else {
				$cstArchivedStudents2017->ResultLetter->HrefValue = "";
			}
			$cstArchivedStudents2017->ResultLetter->TooltipValue = "";

			// IDFile
			if (!ew_Empty($cstArchivedStudents2017->IDFile->Upload->DbValue)) {
				$cstArchivedStudents2017->IDFile->HrefValue = ew_UploadPathEx(FALSE, $cstArchivedStudents2017->IDFile->UploadPath) . ((!empty($cstArchivedStudents2017->IDFile->ViewValue)) ? $cstArchivedStudents2017->IDFile->ViewValue : $cstArchivedStudents2017->IDFile->CurrentValue);
				if ($cstArchivedStudents2017->Export <> "") $cstArchivedStudents2017->IDFile->HrefValue = ew_ConvertFullUrl($cstArchivedStudents2017->IDFile->HrefValue);
			} else {
				$cstArchivedStudents2017->IDFile->HrefValue = "";
			}
			$cstArchivedStudents2017->IDFile->TooltipValue = "";

			// ReasonForLeaving
			$cstArchivedStudents2017->ReasonForLeaving->HrefValue = "";
			$cstArchivedStudents2017->ReasonForLeaving->TooltipValue = "";
		}

		// Call Row Rendered event
		if ($cstArchivedStudents2017->RowType <> EW_ROWTYPE_AGGREGATEINIT)
			$cstArchivedStudents2017->Row_Rendered();
	}

	// Export data in HTML/CSV/Word/Excel/XML/Email format
	function ExportData() {
		global $cstArchivedStudents2017;
		$utf8 = FALSE;
		$bSelectLimit = FALSE;

		// Load recordset
		if ($bSelectLimit) {
			$this->lTotalRecs = $cstArchivedStudents2017->SelectRecordCount();
		} else {
			if ($rs = $this->LoadRecordset())
				$this->lTotalRecs = $rs->RecordCount();
		}
		$this->lStartRec = 1;
		$this->SetUpStartRec(); // Set up start record position

		// Set the last record to display
		if ($this->lDisplayRecs < 0) {
			$this->lStopRec = $this->lTotalRecs;
		} else {
			$this->lStopRec = $this->lStartRec + $this->lDisplayRecs - 1;
		}
		if (!$rs) {
			header("Content-Type:"); // Remove header
			header("Content-Disposition:");
			$this->ShowMessage();
			return;
		}
		if ($cstArchivedStudents2017->Export == "xml") {
			$XmlDoc = new cXMLDocument(EW_XML_ENCODING);
			$XmlDoc->AddRoot();
		} else {
			$ExportDoc = new cExportDocument($cstArchivedStudents2017, "v");
			$ExportDoc->ExportHeader();
			if ($ExportDoc->Horizontal) { // Horizontal format, write header
				$ExportDoc->BeginExportRow();
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Title);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->FirstName);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Surname);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->KnownAs);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Organisation);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->OrganisationType);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->StudentNumber);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->CCEFacilitatorID);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Project);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->ProjectDiscipline);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->IDNumber);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->ECSANumber);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Age);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HighestQual);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->AreaDiscipline);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Telephone);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Cellphone);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->EmailAddress);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HomeAddress);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->WorkAddress);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->PostalAddress);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Designation);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Department);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->CESAAccountNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->VATNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->DietaryRequirements);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->CVFile);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->QualCertificate1);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->QualCertificate2);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->QualCertificate3);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MemorandumFile);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->AgreementFile);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->OrderNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByName);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByDesignation);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByTelNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByFaxNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByCellNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BookedByEmail);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->WebUsername);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->WebPassword);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MentorName);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MentorDesig);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MentorTel);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MentorCell);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->MentorEmail);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HRManagerName);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HRManagerDesignation);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HRManagerTelNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HRManagerCellNo);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->HRManagerEmail);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->LengthEmploy);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->BlockAccess);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Archived);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->ResultLetter);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->Achieved);
				$ExportDoc->ExportCaption($cstArchivedStudents2017->IDFile);
				$ExportDoc->EndExportRow();
			}
		}

		// Move to first record
		$this->lRecCnt = $this->lStartRec - 1;
		if (!$rs->EOF) {
			$rs->MoveFirst();
			if (!$bSelectLimit && $this->lStartRec > 1)
				$rs->Move($this->lStartRec - 1);
		}
		while (!$rs->EOF && $this->lRecCnt < $this->lStopRec) {
			$this->lRecCnt++;
			if (intval($this->lRecCnt) >= intval($this->lStartRec)) {
				$this->LoadRowValues($rs);

				// Render row
				$cstArchivedStudents2017->CssClass = "";
				$cstArchivedStudents2017->CssStyle = "";
				$cstArchivedStudents2017->RowType = EW_ROWTYPE_VIEW; // Render view
				$this->RenderRow();
				if ($cstArchivedStudents2017->Export == "xml") {
					$XmlDoc->AddRow();
					$XmlDoc->AddField('Title', $cstArchivedStudents2017->Title->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('FirstName', $cstArchivedStudents2017->FirstName->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Surname', $cstArchivedStudents2017->Surname->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('KnownAs', $cstArchivedStudents2017->KnownAs->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Organisation', $cstArchivedStudents2017->Organisation->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('OrganisationType', $cstArchivedStudents2017->OrganisationType->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('StudentNumber', $cstArchivedStudents2017->StudentNumber->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('CCEFacilitatorID', $cstArchivedStudents2017->CCEFacilitatorID->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Project', $cstArchivedStudents2017->Project->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('ProjectDiscipline', $cstArchivedStudents2017->ProjectDiscipline->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('IDNumber', $cstArchivedStudents2017->IDNumber->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('ECSANumber', $cstArchivedStudents2017->ECSANumber->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Age', $cstArchivedStudents2017->Age->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HighestQual', $cstArchivedStudents2017->HighestQual->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('AreaDiscipline', $cstArchivedStudents2017->AreaDiscipline->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Telephone', $cstArchivedStudents2017->Telephone->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Cellphone', $cstArchivedStudents2017->Cellphone->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('EmailAddress', $cstArchivedStudents2017->EmailAddress->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HomeAddress', $cstArchivedStudents2017->HomeAddress->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('WorkAddress', $cstArchivedStudents2017->WorkAddress->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('PostalAddress', $cstArchivedStudents2017->PostalAddress->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Designation', $cstArchivedStudents2017->Designation->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Department', $cstArchivedStudents2017->Department->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('CESAAccountNo', $cstArchivedStudents2017->CESAAccountNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('VATNo', $cstArchivedStudents2017->VATNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('DietaryRequirements', $cstArchivedStudents2017->DietaryRequirements->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('CVFile', $cstArchivedStudents2017->CVFile->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('QualCertificate1', $cstArchivedStudents2017->QualCertificate1->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('QualCertificate2', $cstArchivedStudents2017->QualCertificate2->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('QualCertificate3', $cstArchivedStudents2017->QualCertificate3->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MemorandumFile', $cstArchivedStudents2017->MemorandumFile->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('AgreementFile', $cstArchivedStudents2017->AgreementFile->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('OrderNo', $cstArchivedStudents2017->OrderNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByName', $cstArchivedStudents2017->BookedByName->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByDesignation', $cstArchivedStudents2017->BookedByDesignation->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByTelNo', $cstArchivedStudents2017->BookedByTelNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByFaxNo', $cstArchivedStudents2017->BookedByFaxNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByCellNo', $cstArchivedStudents2017->BookedByCellNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BookedByEmail', $cstArchivedStudents2017->BookedByEmail->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('WebUsername', $cstArchivedStudents2017->WebUsername->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('WebPassword', $cstArchivedStudents2017->WebPassword->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MentorName', $cstArchivedStudents2017->MentorName->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MentorDesig', $cstArchivedStudents2017->MentorDesig->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MentorTel', $cstArchivedStudents2017->MentorTel->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MentorCell', $cstArchivedStudents2017->MentorCell->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('MentorEmail', $cstArchivedStudents2017->MentorEmail->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HRManagerName', $cstArchivedStudents2017->HRManagerName->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HRManagerDesignation', $cstArchivedStudents2017->HRManagerDesignation->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HRManagerTelNo', $cstArchivedStudents2017->HRManagerTelNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HRManagerCellNo', $cstArchivedStudents2017->HRManagerCellNo->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('HRManagerEmail', $cstArchivedStudents2017->HRManagerEmail->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('LengthEmploy', $cstArchivedStudents2017->LengthEmploy->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('BlockAccess', $cstArchivedStudents2017->BlockAccess->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Archived', $cstArchivedStudents2017->Archived->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('ResultLetter', $cstArchivedStudents2017->ResultLetter->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('Achieved', $cstArchivedStudents2017->Achieved->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
					$XmlDoc->AddField('IDFile', $cstArchivedStudents2017->IDFile->ExportValue($cstArchivedStudents2017->Export, $cstArchivedStudents2017->ExportOriginalValue));
				} else {
					$ExportDoc->BeginExportRow(TRUE); // Allow CSS styles if enabled
					$ExportDoc->ExportField($cstArchivedStudents2017->Title);
					$ExportDoc->ExportField($cstArchivedStudents2017->FirstName);
					$ExportDoc->ExportField($cstArchivedStudents2017->Surname);
					$ExportDoc->ExportField($cstArchivedStudents2017->KnownAs);
					$ExportDoc->ExportField($cstArchivedStudents2017->Organisation);
					$ExportDoc->ExportField($cstArchivedStudents2017->OrganisationType);
					$ExportDoc->ExportField($cstArchivedStudents2017->StudentNumber);
					$ExportDoc->ExportField($cstArchivedStudents2017->CCEFacilitatorID);
					$ExportDoc->ExportField($cstArchivedStudents2017->Project);
					$ExportDoc->ExportField($cstArchivedStudents2017->ProjectDiscipline);
					$ExportDoc->ExportField($cstArchivedStudents2017->IDNumber);
					$ExportDoc->ExportField($cstArchivedStudents2017->ECSANumber);
					$ExportDoc->ExportField($cstArchivedStudents2017->Age);
					$ExportDoc->ExportField($cstArchivedStudents2017->HighestQual);
					$ExportDoc->ExportField($cstArchivedStudents2017->AreaDiscipline);
					$ExportDoc->ExportField($cstArchivedStudents2017->Telephone);
					$ExportDoc->ExportField($cstArchivedStudents2017->Cellphone);
					$ExportDoc->ExportField($cstArchivedStudents2017->EmailAddress);
					$ExportDoc->ExportField($cstArchivedStudents2017->HomeAddress);
					$ExportDoc->ExportField($cstArchivedStudents2017->WorkAddress);
					$ExportDoc->ExportField($cstArchivedStudents2017->PostalAddress);
					$ExportDoc->ExportField($cstArchivedStudents2017->Designation);
					$ExportDoc->ExportField($cstArchivedStudents2017->Department);
					$ExportDoc->ExportField($cstArchivedStudents2017->CESAAccountNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->VATNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->DietaryRequirements);
					$ExportDoc->ExportField($cstArchivedStudents2017->CVFile);
					$ExportDoc->ExportField($cstArchivedStudents2017->QualCertificate1);
					$ExportDoc->ExportField($cstArchivedStudents2017->QualCertificate2);
					$ExportDoc->ExportField($cstArchivedStudents2017->QualCertificate3);
					$ExportDoc->ExportField($cstArchivedStudents2017->MemorandumFile);
					$ExportDoc->ExportField($cstArchivedStudents2017->AgreementFile);
					$ExportDoc->ExportField($cstArchivedStudents2017->OrderNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByName);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByDesignation);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByTelNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByFaxNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByCellNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->BookedByEmail);
					$ExportDoc->ExportField($cstArchivedStudents2017->WebUsername);
					$ExportDoc->ExportField($cstArchivedStudents2017->WebPassword);
					$ExportDoc->ExportField($cstArchivedStudents2017->MentorName);
					$ExportDoc->ExportField($cstArchivedStudents2017->MentorDesig);
					$ExportDoc->ExportField($cstArchivedStudents2017->MentorTel);
					$ExportDoc->ExportField($cstArchivedStudents2017->MentorCell);
					$ExportDoc->ExportField($cstArchivedStudents2017->MentorEmail);
					$ExportDoc->ExportField($cstArchivedStudents2017->HRManagerName);
					$ExportDoc->ExportField($cstArchivedStudents2017->HRManagerDesignation);
					$ExportDoc->ExportField($cstArchivedStudents2017->HRManagerTelNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->HRManagerCellNo);
					$ExportDoc->ExportField($cstArchivedStudents2017->HRManagerEmail);
					$ExportDoc->ExportField($cstArchivedStudents2017->LengthEmploy);
					$ExportDoc->ExportField($cstArchivedStudents2017->BlockAccess);
					$ExportDoc->ExportField($cstArchivedStudents2017->Archived);
					$ExportDoc->ExportField($cstArchivedStudents2017->ResultLetter);
					$ExportDoc->ExportField($cstArchivedStudents2017->Achieved);
					$ExportDoc->ExportField($cstArchivedStudents2017->IDFile);
					$ExportDoc->EndExportRow();
				}
			}
			$rs->MoveNext();
		}
		if ($cstArchivedStudents2017->Export <> "xml")
			$ExportDoc->ExportFooter();

		// Close recordset
		$rs->Close();

		// Clean output buffer
		if (!EW_DEBUG_ENABLED && ob_get_length())
			ob_end_clean();

		// Write BOM if utf-8
		if ($utf8 && !in_array($cstArchivedStudents2017->Export, array("email", "xml")))
			echo "\xEF\xBB\xBF";

		// Write debug message if enabled
		if (EW_DEBUG_ENABLED)
			echo ew_DebugMsg();

		// Output data
		if ($cstArchivedStudents2017->Export == "xml") {
			header("Content-Type: text/xml");
			echo $XmlDoc->XML();
		} elseif ($cstArchivedStudents2017->Export == "email") {
			$this->ExportEmail($ExportDoc->Text);
			$this->Page_Terminate($cstArchivedStudents2017->ExportReturnUrl());
		} else {
			echo $ExportDoc->Text;
		}
	}

	// Export email
	function ExportEmail($EmailContent) {
		global $Language, $cstArchivedStudents2017;
		$sSender = @$_GET["sender"];
		$sRecipient = @$_GET["recipient"];
		$sCc = @$_GET["cc"];
		$sBcc = @$_GET["bcc"];
		$sContentType = @$_GET["contenttype"];

		// Subject
		$sSubject = ew_StripSlashes(@$_GET["subject"]);
		$sEmailSubject = $sSubject;

		// Message
		$sContent = ew_StripSlashes(@$_GET["message"]);
		$sEmailMessage = $sContent;

		// Check sender
		if ($sSender == "") {
			$this->setMessage($Language->Phrase("EnterSenderEmail"));
			return;
		}
		if (!ew_CheckEmail($sSender)) {
			$this->setMessage($Language->Phrase("EnterProperSenderEmail"));
			return;
		}

		// Check recipient
		if (!ew_CheckEmailList($sRecipient, EW_MAX_EMAIL_RECIPIENT)) {
			$this->setMessage($Language->Phrase("EnterProperRecipientEmail"));
			return;
		}

		// Check cc
		if (!ew_CheckEmailList($sCc, EW_MAX_EMAIL_RECIPIENT)) {
			$this->setMessage($Language->Phrase("EnterProperCcEmail"));
			return;
		}

		// Check bcc
		if (!ew_CheckEmailList($sBcc, EW_MAX_EMAIL_RECIPIENT)) {
			$this->setMessage($Language->Phrase("EnterProperBccEmail"));
			return;
		}

		// Check email sent count
		if (!isset($_SESSION[EW_EXPORT_EMAIL_COUNTER]))
			$_SESSION[EW_EXPORT_EMAIL_COUNTER] = 0;
		if (intval($_SESSION[EW_EXPORT_EMAIL_COUNTER]) > EW_MAX_EMAIL_SENT_COUNT) {
			$this->setMessage($Language->Phrase("ExceedMaxEmailExport"));
			return;
		}
		if ($sEmailMessage <> "") {
			$sEmailMessage = ew_RemoveXSS($sEmailMessage);
			$sEmailMessage .= ($sContentType == "url") ? "\r\n\r\n" : "<br><br>";
		}
		if ($sContentType == "url") {
			$sUrl = ew_ConvertFullUrl(ew_CurrentPage() . "?" . $this->ExportQueryString());
			$sEmailMessage .= $sUrl; // send URL only
		} else {
			$sEmailMessage .= $EmailContent; // send HTML
		}

		// Send email
		$Email = new cEmail();
		$Email->Sender = $sSender; // Sender
		$Email->Recipient = $sRecipient; // Recipient
		$Email->Cc = $sCc; // Cc
		$Email->Bcc = $sBcc; // Bcc
		$Email->Subject = $sEmailSubject; // Subject
		$Email->Content = $sEmailMessage; // Content
		$Email->Format = ($sContentType == "url") ? "text" : "html";
		$Email->Charset = EW_EMAIL_CHARSET;
		$EventArgs = array();
		$bEmailSent = FALSE;
		if ($cstArchivedStudents2017->Email_Sending($Email, $EventArgs))
			$bEmailSent = $Email->Send();

		// Check email sent status
		if ($bEmailSent) {

			// Update email sent count
			$_SESSION[EW_EXPORT_EMAIL_COUNTER]++;

			// Sent email success
			$this->setMessage($Language->Phrase("SendEmailSuccess"));
		} else {

			// Sent email failure
			$this->setMessage($Email->SendErrDescription);
		}
	}

	// Export QueryString
	function ExportQueryString() {
		global $cstArchivedStudents2017;

		// Initialize
		$sQry = "export=html";

		// Add record key QueryString
		$sQry .= "&" . substr($cstArchivedStudents2017->KeyUrl("", ""), 1);
		return $sQry;
	}

	// Page Load event
	function Page_Load() {

		//echo "Page Load";
	}

	// Page Unload event
	function Page_Unload() {

		//echo "Page Unload";
	}

	// Page Redirecting event
	function Page_Redirecting(&$url) {

		// Example:
		//$url = "your URL";

	}

	// Message Showing event
	function Message_Showing(&$msg) {

		// Example:
		//$msg = "your new message";

	}
}
?>