<%[@ IncludeFile "Code/Util.vbs" ]%> <%[@ IncludeFile "Code/Lang.vbs" ]%> <%[ strTitle = Dic("TocIndexOccupancies") strAltToggle = Util.FormatString("{} {}", Dic("TocExpandCollapseAll"), Dic("Notes")) strAltToggle1 = Util.FormatString("{} {}", Dic("TocExpandCollapseAll"), Dic("References")) Report.TagBr = "
" & vbCRLF ' For debugging, but it does not harm to re-define the
tag InitGlobalVariables ]%> @[ Report.WriteText Session("Title") ]@ - Genealogy Occupancy/Contacts
<%[ g_ichNotesStart = Report.BufferLength ]%> <%[ ichNotesEnd = Report.BufferLength ]%> <%[ g_ichReferencesStart = Report.BufferLength ]%> <%[ ichReferencesEnd = Report.BufferLength ]%>

@[ Report.WriteText strTitle ]@


<%[ Dim strComments,strComment, ich For Each c In Contacts Set collReferences = c.References strComments=split(c.Comment,vbLf) strComment="" If Ubound(strComments) >= 0 Then strComment = strComments(0) ' use 1st line of comment for subheading if present Report.WriteFormattedLn "

{&t}

", c.ID, Util.FirstNonEmpty(c.Place.Name, c.Summary, Util.IfElse(c.Comment<> "" And Len(c.Comment) < 80,c.Comment,"") ,Dic("Occupancy") & " (" & Dic("Ref") & c.ID & ")") ich = Report.BufferLength Report.WritePhraseDic "PhOccupancy", c.type, StrHtmlHyperlinkPlace(c.Place), c.Duration, c.DateStart.FormatDateSpan(c.DateEnd) If Report.BufferLength > ich And c.summary <> "" Then Report.WriteBr Report.WritePhraseDic "PhContact", c.telephone, c.Fax, Util.FormatHtmlHyperlink(Util.IfElse(c.Email <> "","mailto:" & c.Email,""), c.Email), Util.FormatHtmlHyperlink(c.Homepage, ,"target='_blank'"), c.Type, c.Place WriteHtmlFootnoteRef c.Source WriteHtmlAdditionalInformation(c) WriteHtmlAnnotation Dic("AnnotationOccupancy"), c.Comment WriteHtmlReferences c, false WriteHtmlAllFootnotes c.Sources Report.WriteLn "
" Next If (g_ichNotesStart >= 0) Then ' We have no annotations, so remove the "Show All Notes | Hide All Notes" Report.BufferRemoveAt g_ichNotesStart, ichNotesEnd End If If g_ichReferencesStart >= 0 Then ' We have no place references, so remove the "Show All References | Hide All References" Report.BufferRemoveAt ichReferencesStart, ichReferencesEnd End If ]%>
<%[ WriteHtmlFramesetSafeguard("Contacts") ]%>