/* 6,0,0,201
--------------------------------------------------------------------------

Copyright (c) 2001-9 Corporate Practical Solutions and Partners.

This software is the property of Corporate Practical Solutions and Partners.

No part of this software may be reproduced in any form,
without the prior consent of Corporate Practical Solutions.

--------------------------------------------------------------------------
*/
  var DP_DefaultTheme = 1; var	DP_ChartTheme = DP_DefaultTheme; var DP_AlternateRowColor = "#C0C0C0"; var DP_SearchRowColor = "#FFFFDD";  var GB_MaintenanceMode = (window.location.href.indexOf("?maintenance") != -1); var GB_MaintenanceModex = (window.location.href.indexOf("?maintenancex") != -1); var GB_AnyChanges = false; var GB_Feedback = false; var GB_AnimateCharts = true; var GB_ChartIncludeUnknown = false; var GB_ShowWUP = false;  var ColorArray = new Array(); var BrightTones = "FFFF00,008000,0000FF,800080,FFA500,FF0000,C0C0C0"; var CorporateTones = "6699CE,585E78,FFFFC9,444444,98CDFF,000000,999ACA,CCCDC8,010066,999999";  /* ------------------------------------------------------------------------------------------------- Message box functions */  function myMessageBox(MessageText, SubText) { var	HTML;  HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - 200) + 'px; top: ' + (window.document.body.scrollTop + 100) + 'px; height: 120px; width: 400px; padding: 1em; z-index:201">';
 HTML = HTML + '<table width="400" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="400" border="0" cellpadding="2" cellspacing="0" bgcolor="#FFFFFF"><tr><td colspan="3"><img src="' + DP_ImagePath + '/Assets/9002.jpg"></td></tr><tr><td colspan="3" align="center"><B>' + MessageText + '</B></td></tr><tr><td colspan="3" align="center"><span class="PageNumber">' + SubText + '</span></td></tr><tr><td colspan="3" align="center"><INPUT TYPE="BUTTON" onClick="HideMessage(\'Message\')" STYLE="width:50px" VALUE="OK"></td></tr></table></td></tr></table></DIV>'; myGetElementById("Message").innerHTML = HTML;  if (! Mozilla) myGetElementById("Mask").style.filter = 'alpha(opacity=20)'; else myGetElementById("Mask").style.opacity = '0.2'; myGetElementById("Mask").style.display = "block"; myGetElementById("Mask").style.width = MaxWidth() + 'px'; myGetElementById("Mask").style.height = MaxHeight() + 'px'; myGetElementById("Mask").style.top = "0px"; myGetElementById("Mask").style.left = "0px";
 SelectBoxes(true); FusionCharts(true); HideMenu("All"); Buttons("none"); myGetElementById("Chart").style.display = "none"; myGetElementById("Message").style.display = ""; }  function HideMessage(MessageType) { if (MessageType == "PopupChart") ShowData(); if (MessageType == "SearchOptions") { DP_SearchCS = myGetElementById("SearchCS").checked; WriteCookie(); } SelectBoxes(false); FusionCharts(false); ShowMenu(); myGetElementById("Message").style.display = "none"; myGetElementById("Mask").style.display = "none"; Buttons(""); if (ChartAvailable()) if (SH_ViewArray[DP_CurrentViewNumber].ViewSupportCharts) ShowChart(false, "Chart", 150, 150, "Vertical", 10); if (myGetElementById("Search")) { if (myGetElementById("Search").value != "") myGetElementById("Search").select(); } }  function Buttons(Mode) { if ((! GB_MaintenanceMode) && (myGetElementById("SetwidthSpan"))) myGetElementById("SetwidthSpan").style.display = Mode; if ((GB_Feedback) && (myGetElementById("FeedbackSpan"))) myGetElementById("FeedbackSpan").style.display = Mode; } 
 function SelectBoxes(Disabled)		/* To handle IE bug */ { var coll = document.getElementsByTagName("SELECT");  for (i=0; i<coll.length; i++) { if (coll[i].id.indexOf("LSELECT") != -1) { if (Disabled) coll[i].style.display = "None"; else coll[i].style.display = ""; } else if (coll[i].id.indexOf("MSELECT") == -1) coll[i].disabled = Disabled; } }  function FusionCharts(Disabled)		/* To handle IE bug */ { var coll = document.getElementsByTagName("OBJECT");  for (i=0; i<coll.length; i++) { if (coll[i].id.indexOf("FusionCharts") == -1) { if (Disabled) coll[i].style.display = "None"; else coll[i].style.display = ""; } } if (SH_Report == "systemhound Home") { if (Disabled) myGetElementById("RSSSpan").style.display = "None"; else myGetElementById("RSSSpan").style.display = ""; } }  function GetPageNumber(ItemNumber) { var Count;  for (Count=1; Count<DP_Pages.length; Count++) { if (DP_Pages[Count] > ItemNumber) return(Count -1); } return(Count - 1); }  /* ------------------------------------------------------------------------------------------------- Search functions */ 
 function doSearch(SearchString) { var SearchString; var Count, Count2, SearchItems, Matched, Pos, FoundAlready;  if (! SearchString) SearchString = myGetElementById("Search").value;  FoundAlready = (myGetElementById("SearchButton").value == "next");  if (SearchString == "") return; SearchString = ProtectReservedCharacters(SearchString);  if 	(SH_FieldArray[DP_SortColumn].FieldType == 2) SearchString = "*" + SearchString + "*";  if (! DP_SearchCS) SearchString = SearchString.toLowerCase(); if ((Pos = SearchString.indexOf("*")) != -1) { WildCardSearch = true; SearchItems = SearchString.split("*"); } else WildCardSearch = false;  DP_SearchItem = -1; for (Count=DP_SearchStart; ((Count<SH_ItemCount) && (DP_SearchItem == -1)); Count++) { if (SH_ItemArray[Count].Flags[0]) { if (SH_FieldArray[DP_SortColumn].FieldType == 2) { StringToSearch = AsciiDateTime(SH_ItemArray[Count].Field[DP_SortColumn]) + " "; StringToSearch = ProtectReservedCharacters(StringToSearch); } else StringToSearch = SH_ItemArray[Count].Field[DP_SortColumn] + " "; if (! DP_SearchCS)
 StringToSearch = StringToSearch.toLowerCase(); if (! WildCardSearch) { code = (StringToSearch >= SearchString); if (code) { if (SearchString == StringToSearch.substring(0, SearchString.length)) { matched = true; if (StringToSearch == SearchString) SearchExactMatch = true; else SearchExactMatch = false; DP_SearchItem = Count; DP_SearchStart = Count + 1; DP_LastSearch = UnProtectReservedCharacters(SearchString); } } } else { if (MatchString(StringToSearch, SearchString)) { matched = true; SearchExactMatch = true; DP_SearchItem = Count; DP_SearchStart = Count + 1; if 	(SH_FieldArray[DP_SortColumn].FieldType == 2) SearchString = SearchString.substring(1, SearchString.length-1); DP_LastSearch = UnProtectReservedCharacters(SearchString); } } } } if (DP_SearchItem != -1) { DP_CurrentPage = GetPageNumber(DP_SearchItem); RefreshDisplay(false, false, false); } else { DP_SearchSelected = true; if (! FoundAlready)
 myMessageBox('Unable to find "' + SearchString + '" in the ' + SH_FieldArray[DP_SortColumn].FieldName + ' column', 'This may be because the display is not currently sorted by the column you want to search. If this is the case please select the required column by clicking the column heading and try searching again.'); else myMessageBox('"' + SearchString + '" not found', 'No more occurences of this have been found in the ' + SH_FieldArray[DP_SortColumn].FieldName + ' column.', ''); } }  function SearchChange() { ResetSearch(); }  function ResetSearch() { myGetElementById("SearchButton").value = "find"; DP_LastSearch = ""; DP_SearchStart = 0; DP_SearchMachine = -1; }  function doSearchOptions() { var	HTML;  HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - 150) + 'px; top: ' + (window.document.body.scrollTop + 100) + 'px; height: 120px; width: 300px; padding: 1em; z-index:201">';
 HTML = HTML + '<table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#FFFFFF"><tr><td colspan="3"><img src="' + DP_ImagePath + '/Assets/9002.jpg"></td></tr><tr><td colspan="3" align="center"><B>Search options</B></td></tr><tr valign="middle"><td width="10">&nbsp;</td><td width="25"><INPUT TYPE="CHECKBOX" ID="SearchCS"></td><td><SPAN CLASS="PageNumber">Case sensitive (for a faster search)</SPAN></td></tr><tr valign="middle"><td width="10">&nbsp;</td><td colspan="2"><SPAN CLASS="PageNumber">Note : \'*\' wildcards are supported. eg. Microsoft*, *flash*, *driver</SPAN></td></tr><tr><td colspan="3" align="center"><INPUT TYPE="BUTTON" onClick="HideMessage(\'SearchOptions\')" STYLE="width:50px" VALUE="OK"></td></tr></table></td></tr></table></DIV>'; myGetElementById("Message").innerHTML = HTML;  if (! Mozilla) myGetElementById("Mask").style.filter = 'alpha(opacity=20)';
 else myGetElementById("Mask").style.opacity = '0.2'; myGetElementById("Mask").style.width = MaxWidth() + 'px'; myGetElementById("Mask").style.height = MaxHeight() + 'px'; myGetElementById("Mask").style.top = "0px"; myGetElementById("Mask").style.left = "0px"; myGetElementById("Mask").style.display = "block"; SelectBoxes(true); FusionCharts(true); HideMenu("All"); Buttons("none"); myGetElementById("Chart").style.display = "none"; myGetElementById("Message").style.display = ""; myGetElementById("SearchCS").checked = DP_SearchCS; }  /* ------------------------------------------------------------------------------------------------- Routines to handle reinitialisation of the screen */  function ResetPage() { DP_CurrentPage = 0; ResetSearch(); }  function ResetSearch() { myGetElementById("SearchButton").value = "find"; DP_LastSearch = ""; DP_SearchStart = 0; }  function ResetFilters() { DP_ShowARP = true; DP_ShowSVC = true; DP_ShowREG = true;  }  /* -------------------------------------------------------------------------------------------------
 Various miscellaneous */  function CompareVersionNumbers(v1, v2, Ascending) { Items1 = v1.split("."); Items2 = v2.split(".");  if (Items1.length > Items2.length) { for (count=Items2.length; count<Items1.length; count++) Items2.push(-1); } else { for (count=Items1.length; count<Items2.length; count++) Items1.push(-1); }  for (Count=0; Count<Items1.length; Count++) { Item1Num = parseInt(Items1[Count]); if (isNaN(Item1Num)) Item1Num = -1; Item2Num = parseInt(Items2[Count]); if (isNaN(Item2Num)) Item2Num = -1;  if (Item1Num > Item2Num) { if (Ascending) return(1); else return(-1); } if (Item1Num < Item2Num) { if (Ascending) return(-1); else return(1); } } return(0); }  function ParseName(buffer) { var WindowsString = (buffer.indexOf("Windows") != -1);  buffer = buffer + ""; if (SH_Report == "Master Hardware") { buffer = buffer.replace(/processor/g, ""); buffer = buffer.replace(/\(R\)/g, ""); buffer = buffer.replace(/\(C\)/g, ""); buffer = buffer.replace(/\(r\)/g, ""); buffer = buffer.replace(/\(c\)/g, ""); buffer = buffer.replace(/Intel/g, "");
 buffer = buffer.replace(/Pentium/g, "Pent."); buffer = buffer.replace(/CPU/g, ""); buffer = buffer.replace(/cpu/g, ""); } if (WindowsString) { buffer = buffer.replace(/Windows NT/g, "NT"); buffer = buffer.replace(/Windows XP/g, "XP"); buffer = buffer.replace(/Windows 2000/g, "W2K"); buffer = buffer.replace(/Windows Server 2003/g, "W2003 svr."); buffer = buffer.replace(/Windows/g, "W"); buffer = buffer.replace(/Personal/g, "Pers."); buffer = buffer.replace(/Professional/g, "Prof."); buffer = buffer.replace(/5\.0/g, ""); buffer = buffer.replace(/5\.1/g, ""); buffer = buffer.replace(/5\.2/g, ""); buffer = buffer.replace(/Build 2600/g, ""); buffer = buffer.replace(/Build 2195/g, ""); buffer = buffer.replace(/Build 1381/g, ""); buffer = buffer.replace(/Build 3790/g, ""); buffer = buffer.replace(/Standard Edition/g, "Std."); buffer = buffer.replace(/Server/g, "svr."); buffer = buffer.replace(/Domain Controller/g, "DC"); buffer = buffer.replace(/Workstation/g, "WS"); buffer = buffer.replace(/Service Pack /g, "SP"); }
 buffer = buffer.replace(/  /g, " "); return(buffer); }  function HotFixName(ApplicationName) { var	Pos, Buffer;  if ((Pos = ApplicationName.indexOf("(KB")) != -1) { Buffer = ApplicationName.substr(Pos+1); Buffer = Buffer.substr(0, Buffer.indexOf(")")); return(Buffer); } else if ((Pos = ApplicationName.indexOf("- KB")) != -1) { Buffer = ApplicationName.substr(Pos+2); if (Buffer.indexOf(" ") != -1) Buffer = Buffer.substr(0, Buffer.indexOf(" ")); return(Buffer); } else if ((Pos = ApplicationName.indexOf("&#40;KB")) != -1) { Buffer = ApplicationName.substr(Pos+5); Buffer = Buffer.substr(0, Buffer.indexOf("&#41;")); return(Buffer); } return(""); }  /* ------------------------------------------------------------------------------------------------- Routines to handle sorting */  function ColumnClick(ColumnNumber) { HideData(); if (DP_SortColumn == ColumnNumber) DP_SortAscending = ! DP_SortAscending; else InitialiseSortDirection(ColumnNumber); DP_SortColumn = ColumnNumber / 1; ResetPage(); setTimeout("RefreshDisplay(true, true, true)", 500); } 
 function InitialiseSortDirection(ColumnNumber) { if (SH_FieldArray[ColumnNumber].ReverseSort) DP_SortAscending = false; else DP_SortAscending = true; }  /* ------------------------------------------------------------------------------------------------- Routines to handle navigation controls */  function SetItemsPerPage() { DP_ItemsPerPage = eval(myGetElementById("IPP").value);  HideData(); setTimeout("RefreshDisplay(true, false, false)", 500); }  function SetManufacturer() { DP_Manufacturer = myGetElementById("MAN").value; DP_ModelType = "any"; DP_Manufacturer = ProtectReservedCharacters(DP_Manufacturer); HideData(); ResetPage(); setTimeout("RefreshDisplay(true, true, true)", 500); }  function SetModelType() { DP_ModelType = myGetElementById("MOD").value; DP_ModelType = ProtectReservedCharacters(DP_ModelType); HideData(); ResetPage(); setTimeout("RefreshDisplay(true, true, true)", 500); }  function SetView(ViewName, ForceResetFilters) { if (ViewName == "") DP_CurrentView = myGetElementById("VIE").value; else DP_CurrentView = ViewName; 
 if ((CurrentView = GetViewNumber(DP_CurrentView)) != -1) { DP_SortColumn = SH_ViewArray[CurrentView].ViewSortColumn; InitialiseSortDirection(DP_SortColumn); ResetPage(); if ((SH_ViewArray[CurrentView].ViewResetFilters) || (ForceResetFilters)) ResetFilters(); HideData(); setTimeout("RefreshDisplay(true, true, true)", 500); } }  function GotoPage(PageReference) { if (PageReference == 'F') DP_CurrentPage = 0; else if (PageReference == 'P') DP_CurrentPage--; else if (PageReference == 'N') DP_CurrentPage++; else if (PageReference == 'L') DP_CurrentPage = DP_Pages.length - 1;  HideData(); setTimeout("RefreshDisplay(false, false, false)", 500); }  function SSClick() { DP_SaveSettings = ! DP_SaveSettings; WriteCookie(); }  function IUClick() { GB_ChartIncludeUnknown = ! GB_ChartIncludeUnknown; }  function ACClick() { GB_AnimateCharts = ! GB_AnimateCharts; }  function ChangeFilter(FilterName) { switch (FilterName) { case "ARP" : DP_ShowARP = (myGetElementById("ViewARP").value == "Show"); break; case "SVC" : DP_ShowSVC = (myGetElementById("ViewSVC").value == "Show");
 break; case "REG" : DP_ShowREG = (myGetElementById("ViewREG").value == "Show"); break; } ResetPage(); HideData(); setTimeout("RefreshDisplay(true, true, true)", 500); }  function RestoreDefaults() { DP_ItemsPerPage = 25; DP_Manufacturer = "any"; DP_ChartTheme = DP_DefaultTheme; SetView(DP_DefaultView, true); if (SH_Report == "Machine Software") { DP_ShowARP = true; DP_ShowSVC = false; DP_ShowREG = false; } }  function GetViewNumber(ViewName) { var Count;  for (Count=0; Count<SH_ViewCount; Count++) { if (SH_ViewArray[Count].ViewName == ViewName) return(Count); } return(0); }  function GetColumnNumber(FieldName) { var Count;  for (Count=0; Count<SH_FieldCount; Count++) { if (SH_FieldArray[Count].FieldName == FieldName) return(Count); } return(-1); }  /* ---------------------------------------------------------------------------------------------- Routines to update the display */  function ShowData() { HidePleaseWait(); myGetElementById("Title").style.display = ""; myGetElementById("DataTable").style.display = "";
 myGetElementById("CopyrightSpan").style.display = ""; myGetElementById("NavigationTable").style.display = ""; myGetElementById("SHLogo").style.display = ""; ShowMenu(); }  function HideData() { HideMenu("All"); myGetElementById("Title").style.display = "none"; myGetElementById("DataTable").style.display = "none"; myGetElementById("CopyrightSpan").style.display = "none"; myGetElementById("NavigationTable").style.display = "none"; myGetElementById("SHLogo").style.display = "none"; ShowPleaseWait(); }  function ShowPleaseWait() { myGetElementById("PleaseWait").innerHTML = '<DIV STYLE="position: absolute; left:300px; top: 50px; height: 200px; width: 200px; padding: 1em; z-index:201"><IMG SRC="' + DP_ImagePath + '/Assets/9003.jpg"></DIV>'; HideChart(); myGetElementById("PleaseWait").style.display = ""; }  function HidePleaseWait() { myGetElementById("PleaseWait").style.display = "none"; }  /* ---------------------------------------------------------------------------------------------- Routines to handle data views*/ 
 function AddView(ViewName, ViewFields, ViewWidths, ViewSortColumn, ViewMasterSearchFilter, ViewResetFilters, ViewSupportCharts, ViewWide) { SH_ViewArray[SH_ViewCount] = new ViewObject(ViewName, ViewFields, ViewWidths, ViewSortColumn, ViewMasterSearchFilter, ViewResetFilters, ViewSupportCharts, ViewWide); SH_ViewCount++; }  function ViewObject(ViewName, ViewFields, ViewWidths, ViewSortColumn, ViewMasterSearchFilter, ViewResetFilters, ViewSupportCharts, ViewWide) { var	Count, Items;  this.ViewName = ViewName; this.ViewFields = ViewFields.split(","); this.ViewTips = new Array(this.ViewFields.length); for (Count=0; Count<this.ViewFields.length; Count++) { Items = this.ViewFields[Count].split("|"); if (Items.length > 1) { this.ViewFields[Count] = Items[0]; this.ViewTips[Count] = Items[1].substring(0, Items[1].length); } else this.ViewTips[Count] = ""; } this.ViewWidths = ViewWidths.split(","); this.ViewSortColumn = ViewSortColumn; this.ViewMasterSearchFilter = ViewMasterSearchFilter; this.ViewResetFilters = ViewResetFilters;
 this.ViewSupportCharts = ViewSupportCharts; this.ViewWide = ViewWide; }  function AddField(FieldName, FieldType, ChartType, ReverseSort) { SH_FieldArray[SH_FieldCount] = new FieldObject(FieldName, FieldType, ChartType, ReverseSort); SH_FieldCount++; }  function FieldObject(FieldName, FieldType, ChartType, ReverseSort) { this.FieldName = FieldName; this.FieldType = FieldType; this.ChartType = ChartType; this.ReverseSort = ReverseSort; }  function GetFieldNumber(FieldName) { var Count;  for (Count=0; Count<SH_FieldCount; Count++) { if (SH_FieldArray[Count].FieldName == FieldName) return(Count); } return(0); }  function GetFieldType(FieldNumber) { if ((SH_FieldArray[FieldNumber].FieldType == 1) || (SH_FieldArray[FieldNumber].FieldType == 2) || (SH_FieldArray[FieldNumber].FieldType == 7)) return(0);														/* Numeric */ else if (SH_FieldArray[FieldNumber].FieldType == 8) return(2);														/* Version number */ else return(1);														/* Alpha */ }  /* ----------------------------------------- Routines to handle charts and chart data */ 
 function ChartAvailable() { if ((! GB_MaintenanceMode) && (SH_FieldArray.length > 0)) return ((SH_FieldArray[DP_SortColumn].ChartType == "SC") || (SH_FieldArray[DP_SortColumn].ChartType == "TT")); else return(false); }  function BuildChartXML(ChartMovie, ChartOptions, MaxChartValues, ParseNames) { var ColorIndex = 0, ChartCount = 0, AnyData = false;  ChartXML = "<graph " + ChartOptions + ">"; switch (ChartMovie) { case "2DPie.swf" : case "2DColumn.swf" : for (Count=0; ((Count<SH_SortedSummary.length) && (ChartCount < MaxChartValues)); Count++) { if ((SH_SortedSummary[Count].Field[1] > 0) && ((GB_ChartIncludeUnknown) || (SH_SortedSummary[Count].Field[0] != "Unknown"))) { if (ParseNames) { DisplayName = ParseName(UnProtectReservedCharacters(SH_SortedSummary[Count].Field[0])).toLowerCase(); if (DisplayName.length > 18) DisplayName = DisplayName.substr(0,18) + "..."; } else DisplayName = UnProtectReservedCharacters(SH_SortedSummary[Count].Field[0]); DisplayName = DisplayName.replace(/'/g, ""); DisplayName = DisplayName.replace(/&/g, "");
 ChartXML = ChartXML + '<set name=\'' + DisplayName + '\' color=\'' + ColorArray[ColorIndex] + '\' value=\'' + SH_SortedSummary[Count].Field[1] + '\''; ChartXML = ChartXML + '/>'; ColorIndex++; AnyData = true; ChartCount++; if (ColorIndex == ColorArray.length) ColorIndex = 0; } } break; case "SSGrid.swf" : for (Count=0; ((Count<SH_SortedSummary.length) && (ChartCount < MaxChartValues)); Count++) { if ((SH_SortedSummary[Count].Field[1] > 0) && ((GB_ChartIncludeUnknown) || (SH_SortedSummary[Count].Field[0] != "Unknown"))) { if (ParseNames) { DisplayName = ParseName(UnProtectReservedCharacters(SH_SortedSummary[Count].Field[0])).toLowerCase(); if (DisplayName.length > 20) DisplayName = DisplayName.substr(0,20) + "..."; } else DisplayName = UnProtectReservedCharacters(SH_SortedSummary[Count].Field[0]); DisplayName = DisplayName.replace(/'/g, ""); DisplayName = DisplayName.replace(/&/g, ""); ChartXML = ChartXML + "<set name='" + DisplayName + "' color='" + ColorArray[ColorIndex] + "' value='" + SH_SortedSummary[Count].Field[1] + "'/>"; 
 ColorIndex++; AnyData = true; if (ColorIndex == ColorArray.length) ColorIndex = 0; ChartCount++; } } break; } ChartXML = ChartXML + '</graph>'; if (AnyData) return(ChartXML); else return(""); }  function CreateFusionChartHTML(Width, Height, ChartMovie, ChartOptions, ChartTitle, ShowGrid, Style, MaxValues) { var ChartXML, CellPadding;  if (DP_ChartTheme == 1) ColorArray = CorporateTones.split(","); else ColorArray = BrightTones.split(",");  if (Style == "Horizontal") CellPadding = "0"; else CellPadding = "0";  if (ChartMovie != "SSGrid.swf") { Name = "MainChart"; if (Style == "Vertical") { FusionChartHTML = '<TABLE WIDTH="100%" CELLPADDING="' + CellPadding + '" BORDER="0" CELLSPACING="0">';
 FusionChartHTML = FusionChartHTML + '<TR><TD><TABLE WIDTH="' + Width + '"><TR><TD ALIGN="CENTER" CLASS="ArticleHeading">' + ChartTitle + '</TD><TD VALIGN="TOP"><IMG SRC="' + DP_ImagePath + '/Assets/1005.jpg" HEIGHT="16" width="16" onclick="MaximiseChart()" TITLE="Maximise the chart and display more values" STYLE="CURSOR:pointer"></TD></TR></TABLE></TD></TR>'; } else { FusionChartHTML = '<TABLE WIDTH="100%" CELLPADDING="' + CellPadding + '" BORDER="0" CELLSPACING="0">'; FusionChartHTML = FusionChartHTML + '<TR><TD COLSPAN="3"><TABLE WIDTH="100%" CELLPADDING="0" CELLSPACING="0"><TR><TD ALIGN="CENTER" CLASS="ArticleHeading" COLSPAN="2">' + ChartTitle + '</TD></TR></TABLE></TD></TR><TR><TD COLSPAN="2" HEIGHT="10"></TD></TR>'; } FusionChartHTML = FusionChartHTML + '<TR WIDTH="' + Width + '"><TD ALIGN="CENTER"><OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="' + FlashCodeBase + '" WIDTH="' + Width + '" HEIGHT="' + Height + '" id="' + Name + '" ALIGN="middle">'; } else { Name = "IndexChart";
 FusionChartHTML = '<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="' + FlashCodeBase + '" WIDTH="' + Width + '" HEIGHT="' + Height + '" id="' + Name + '" ALIGN="middle">'; }  if ((ChartXML = BuildChartXML(ChartMovie, ChartOptions, MaxValues, (Style == "Vertical"))) == "") return("");  FusionChartHTML = FusionChartHTML + '<PARAM NAME=movie VALUE="' + DP_ImagePath + '/../Charts/' + ChartMovie +'">'; FusionChartHTML = FusionChartHTML + '<PARAM NAME=FlashVars VALUE="&chartWidth=' + Width + '&chartHeight=' + Height; FusionChartHTML = FusionChartHTML + '&dataXML=' + ChartXML; if (ChartMovie == "SSGrid.swf") FusionChartHTML = FusionChartHTML + '&fontColor=000000'; FusionChartHTML = FusionChartHTML + '">'; FusionChartHTML = FusionChartHTML + '<PARAM NAME=quality VALUE=high>'; FusionChartHTML = FusionChartHTML + '<PARAM NAME=bgcolor VALUE=#FFFFFF>'; FusionChartHTML = FusionChartHTML + '<EMBED src="' + DP_ImagePath + '/../Charts/' + ChartMovie +'" FlashVars="&chartWidth=' + Width + '&chartHeight=' + Height;
 FusionChartHTML = FusionChartHTML + '&dataXML=' + ChartXML; if (ChartMovie == "SSGrid.swf") FusionChartHTML = FusionChartHTML + '&fontColor=000000'; FusionChartHTML = FusionChartHTML + '" quality=high bgcolor=#FFFFFF WIDTH="' + Width + '" HEIGHT="' + Height + '" NAME="' + Name + '" ALIGN="middle" TYPE="application/x-shockwave-flash" PLUGINSPAGE="' + FlashCodeBase2 + '"></EMBED>';  FusionChartHTML = FusionChartHTML + '</OBJECT>';  if (ShowGrid) { if (ChartMovie != "SSGrid.swf") { if (Style == "Vertical") FusionChartHTML = FusionChartHTML + '</TD></TR><TR><TD>'; else FusionChartHTML = FusionChartHTML + '</TD><TD WIDTH="10">&nbsp;</TD><TD ALIGN="CENTER" VALIGN="CENTER">'; } if (Style == "Vertical") FusionChartHTML = FusionChartHTML + CreateFusionChartHTML(Width, Height, "SSGrid.swf", "bgAlpha='0' chartTopMargin='0' chartBottomMargin='0' decimalPrecision='0' showPercentageValues='1' showNames='1' showValues='0' showPercentageInLabel='1'", "", false, Style, MaxValues); else
 FusionChartHTML = FusionChartHTML + CreateFusionChartHTML(Width-10, Height, "SSGrid.swf", "bgAlpha='0' chartTopMargin='0' chartBottomMargin='0' decimalPrecision='0' showPercentageValues='1' showNames='1' showValues='0' showPercentageInLabel='1'", "", false, Style, MaxValues); }  if (ChartMovie != "SSGrid.swf") FusionChartHTML = FusionChartHTML + '</TD></TR></TABLE>'; return(FusionChartHTML); }  function MaximiseChart() { var ChartWidth = (DP_TableWidth / 2); var ChartHeight = (DP_TableWidth / 2);  HideData(); 
 HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - ChartWidth) + 'px; top: 0px; width: ' + (2 * ChartWidth) + 'px; padding: 1em; z-index:201"><img src="' + DP_ImagePath + '/Assets/9011.jpg"><br><br><table width="' + (2 * ChartWidth) + '" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="' + (2 * ChartWidth) + '" bgcolor="#FFFFFF"><tr><td valign="top"><span id="PopupChart"></span></td></tr></table></td></tr><TR><TD VALIGN="CENTER" HEIGHT="30" COLSPAN="2" ALIGN="CENTER"><INPUT TYPE="BUTTON" VALUE="Print" onClick="doPrint()" STYLE="width:100px;background-color: #F0F0F0">&nbsp;<INPUT TYPE="BUTTON" VALUE="Return" onClick="HideMessage(\'PopupChart\')" STYLE="width:100px;background-color: #F0F0F0" title="Click here to return to the systemhound report"></TD></TR></table></DIV>';  if (GB_Feedback) HTML = HTML + FeedbackButton("Maximised chart");  myGetElementById("Message").innerHTML = HTML;  RecalculateSummary(20);
 ShowChart(true, "PopupChart", ChartWidth, ChartHeight, "Horizontal", 20);  myGetElementById("Chart").style.display = "none"; myGetElementById("PleaseWait").style.display = "none"; myGetElementById("Message").style.display = ""; }  function HideChart() { if (ChartObject = myGetElementById("Chart")) ChartObject.style.display = "none"; }  function SortedSummaryObject(ItemName, ItemCount) { this.Field = new Array();  this.Field.push(ItemName); this.Field.push(ItemCount); }  function RecalculatePages() { var	Count, ItemCount;  ItemCount = 0; DP_VisibleItemCount = 0; DP_Pages.length = 0;  for (Count=0; Count<SH_ItemArray.length; Count++) { if (SH_ItemArray[Count].Flags[0]) { ItemCount++; DP_VisibleItemCount++; if ((ItemCount > DP_ItemsPerPage) || (ItemCount == 1)) { DP_Pages.push(Count); ItemCount = 1; } } } }  function RecalculateSummary(MaxValues) { var Tmp_SH_SortedSummary = new Array(); var AllNumbers = true; var ItemCount = 0;  SH_SortedSummary.length = 0;  switch (SH_Report) { case "Master Software" : switch (DP_SortColumn) { case 1 :	/* Application name column */
 GetTop10(2); SH_SortedActualItemCount = SH_SortedSummary.length; return(2); break; case 2 :	/* Manufacturer column */ if (DP_Manufacturer != "any") { GetFirst10(3); SH_SortedActualItemCount = SH_SortedSummary.length; return(3); } break; } break; case "Master Hardware" : switch (DP_SortColumn) { case 10 : 	/* Manufacturer column */ if (DP_Manufacturer != "any") { GetTop10(2); SH_SortedActualItemCount = SH_SortedSummary.length; return(2); } break; } break; case "Software Usage" : switch (DP_SortColumn) { case 1 : 	/* Manufacturer column */ GetTop10(2); SH_SortedActualItemCount = SH_SortedSummary.length; return(2); break; } break; }  if (SH_FieldArray[DP_SortColumn].ChartType == "SC") { LastItem = ""; LastItemCount = 0;  for (Count=0; Count<SH_ItemCount; Count++) { if (SH_ItemArray[Count].Flags[0]) { if (SH_ItemArray[Count].Field[DP_SortColumn] != LastItem) { if (LastItem != "") Tmp_SH_SortedSummary[Tmp_SH_SortedSummary.length] = new SortedSummaryObject(LastItem, LastItemCount); LastItem = SH_ItemArray[Count].Field[DP_SortColumn]; LastItemCount = 1; } else
 LastItemCount++; } } if (LastItem != "") Tmp_SH_SortedSummary[Tmp_SH_SortedSummary.length] = new SortedSummaryObject(LastItem, LastItemCount);  SH_SortedActualItemCount = Tmp_SH_SortedSummary.length; QuickSort(Tmp_SH_SortedSummary, 1, 0, false);  for (Count=0; ((Count < MaxValues) && (Count < Tmp_SH_SortedSummary.length)); Count++) { SH_SortedSummary[Count] = new SortedSummaryObject(Tmp_SH_SortedSummary[Count].Field[0], Tmp_SH_SortedSummary[Count].Field[1]); if (isNaN(Tmp_SH_SortedSummary[Count].Field[0])) AllNumbers = false; }  if (AllNumbers) QuickSort(SH_SortedSummary, 1, 0, false);  Tmp_SH_SortedSummary.length = 0; } else if (SH_FieldArray[DP_SortColumn].ChartType == "TT")	/* Top ten */ { if (! DP_SortAscending) { for (Count=0; ((Count < SH_ItemCount) && (ItemCount < (MaxValues + 1)) && (SH_ItemArray[Count].Field[DP_SortColumn] != -1)); Count++) { if (SH_ItemArray[Count].Flags[0]) { SH_SortedSummary[ItemCount] = new SortedSummaryObject(SH_ItemArray[Count].Field[1], SH_ItemArray[Count].Field[DP_SortColumn]); ItemCount++; } } } else {
 for (Count=SH_ItemCount-1; ((Count >= 0) && (ItemCount < (MaxValues + 1)) && (SH_ItemArray[Count].Field[DP_SortColumn] != -1)); Count--) { if (SH_ItemArray[Count].Flags[0]) { SH_SortedSummary[ItemCount] = new SortedSummaryObject(SH_ItemArray[Count].Field[1], SH_ItemArray[Count].Field[DP_SortColumn]); ItemCount++; } } } SH_SortedActualItemCount = DP_VisibleItemCount; } return(DP_SortColumn); }  function GetFirst10(ColumnNumber)	/* This is a bit of a cludge, need to check performance with a large no. of apps. Essentially puts first 10 (sorted) of a given field into SH_SortedSummary which can then be used by a chart */ { var SaveDP_SortColumn = DP_SortColumn; var SaveDP_SortAscending = DP_SortAscending;  DP_SortColumn = ColumnNumber; DP_SortAscending = false;	/* descending */ QuickSort(SH_ItemArray, DP_SortColumn, GetFieldType(DP_SortColumn), DP_SortAscending);	/* this is where it might be slow */ SH_SortedSummary.length = 0; for (Count=0; Count<SH_ItemCount; Count++) {
 if (SH_ItemArray[Count].Flags[0])	/* this is why you cant just do it once when the page loads */ SH_SortedSummary[SH_SortedSummary.length] = new SortedSummaryObject(SH_ItemArray[Count].Field[1], SH_ItemArray[Count].Field[ColumnNumber]); } DP_SortColumn = SaveDP_SortColumn; DP_SortAscending = SaveDP_SortAscending; QuickSort(SH_ItemArray, DP_SortColumn, GetFieldType(DP_SortColumn), DP_SortAscending);	/* this is where it might be slow */ }  function GetTop10(ColumnNumber)	/* Similar to the routine above, except totals for a given column are calculated as the data is not actually found in any column */ { var Count, Count2, Found;  SH_SortedSummary.length = 0; for (Count=0; Count<SH_ItemCount; Count++) { if (SH_ItemArray[Count].Flags[0])	/* this is why you cant just do it once when the page loads */ { Found = false; for (Count2=0; ((Count2<SH_SortedSummary.length) && (! Found)); Count2++) { if (SH_SortedSummary[Count2].Field[0] == SH_ItemArray[Count].Field[ColumnNumber]) { SH_SortedSummary[Count2].Field[1]++; Found = true; } } if (! Found)
 SH_SortedSummary[SH_SortedSummary.length] = new SortedSummaryObject(SH_ItemArray[Count].Field[ColumnNumber], 1); } } QuickSort(SH_SortedSummary, 1, 0, false); }  function GridHTML(a, URL, PageName, PageView, Argument, Title) { var	HTML, ItemName; var Count = 0, Pos = 0,	ColorIndex = 0;  HTML = '<table cellpadding="0" cellspacing="4" width="250" border="0"><td colspan="3" class="ArticleHeading">' + Title + '</td></tr><tr><td colspan="3" bgcolor="#C0C0C0" height="1" width="100%"></td></tr>';  while ((Count < 10) && (Pos < a.length)) { if (a[Pos].Field[0] != "Unknown") { DisplayName = UnProtectReservedCharacters(a[Pos].Field[0]); DisplayName = ParseName(DisplayName); DisplayName = DisplayName.substr(0, 35); ItemName = a[Pos].Field[0].replace(/&#44;/g, "<<SC>>");
 HTML = HTML + '<tr><td width="12"><table bgcolor="#000000" cellspacing="1"><tr height="10"><td width="10" bgcolor="#' + ColorArray[ColorIndex] + '" STYLE="CURSOR:pointer;" title="Click here for more ' + a[Pos].Field[0] + ' detail" onClick="NavigateToPage(\'' + URL + '\', \'' + PageName + '\', \'' + PageView + '\', \'' + Argument + ItemName + '\');"></td></tr></table></td><td class="ArticleText BlueText"  STYLE="CURSOR:pointer;" title="Click here for more ' + a[Pos].Field[0] + ' detail" onClick="NavigateToPage(\'' + URL + '\', \'' + PageName + '\', \'' + PageView + '\', \'' + Argument + ItemName + '\');" TITLE="' + a[Pos].Field[0] + '">' + DisplayName + '</td><td class="ArticleText" align="center">' + a[Pos].Field[1] + '</td></tr>'; HTML = HTML + '<tr><td colspan="3" bgcolor="#C0C0C0" height="1" width="100%"></td></tr>'; Count++; if (ColorIndex == ColorArray.length) ColorIndex = 0; else ColorIndex++; } Pos++; }  return(HTML); } 
 /* ------------------------------------------------------------------------------------------------- Routines to handle external links */  function FurtherInformation(ApplicationName, Page, Manufacturer) { var	HTML; var TopOffset = 0;  TopOffset = window.document.body.scrollTop;  HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - 150) + 'px; top: ' + TopOffset + 'px; height: 120px; width: 300px; padding: 1em; z-index:201">';
 HTML = HTML + '<table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#FFFFFF"><tr><td colspan="3"><img src="' + DP_ImagePath + '/Assets/9002.jpg"></td></tr><tr><td colspan="3" align="center" class="ArticleHeading">Further information</td></tr><tr><td colspan="3" align="center" class="ArticleLargeText"><br>Further information may be available for ' + ApplicationName + '.</td></tr><tr><td colspan="3" align="center" class="ArticleLargeText"><br>This link refers to an external page on the ' + Manufacturer + ' website. Please confirm that you would like to view the page.</td></tr><tr><td colspan="3" align="center"><br><INPUT TYPE="BUTTON" onClick="ShowExternalPage(\'' + Page + '\', true)" STYLE="width:100px" VALUE="OK">&nbsp;<INPUT TYPE="BUTTON" onClick="HideMessage()" STYLE="width:100px" VALUE="Cancel"></td></tr><tr height="10"><td></td></tr></table></td></tr></table></DIV>';
 myGetElementById("Message").innerHTML = HTML;  if (! Mozilla) myGetElementById("Mask").style.filter = 'alpha(opacity=20)'; else myGetElementById("Mask").style.opacity = '0.2'; myGetElementById("Mask").style.width = MaxWidth() + 'px'; myGetElementById("Mask").style.height = MaxHeight() + 'px'; myGetElementById("Mask").style.top = "0px"; myGetElementById("Mask").style.left = "0px"; myGetElementById("Mask").style.display = "block"; SelectBoxes(true); FusionCharts(true); Buttons("none"); HideMenu("All"); myGetElementById("Chart").style.display = "none";  myGetElementById("Message").style.display = ""; if (SH_Report == "systemhound Home") setTimeout("window.document.body.scrollTop = " + TopOffset, 500); else window.document.body.scrollTop = TopOffset; }  /* ------------------------------------------------------------------------------------------------- */  function ShowExternalPage(PageRef, doHideMessage) { window.open(PageRef, "", "width=800,height=600,resizable=yes,scrollbars=yes"); if (doHideMessage) HideMessage(); } 
 /* ------------------------------------------------------------------------------------------------- Routine to handle applicarion defaults */  function AppDefaults() { var	HTML;  HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - 150) + 'px; top: ' + (window.document.body.scrollTop + 100) + 'px; height: 120px; width: 300px; padding: 1em; z-index:201">'; HTML = HTML + '<table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="300" border="0" cellpadding="2" cellspacing="0" bgcolor="#FFFFFF"><tr><td colspan="3"><img src="' + DP_ImagePath + '/Assets/9002.jpg"></td></tr>'; HTML = HTML + '<tr><td colspan="3" align="center" class="ArticleHeading">Application defaults</td></tr>'; HTML = HTML + '<tr><td colspan="3" height="5"></td></tr><tr><td colspan="3" class="ArticleLargeText" align="Center">This dialog allows you to configure your systemhound page preferences for this computer.</td></tr>';
 HTML = HTML + '<tr><td colspan="3" height="5"></td></tr><tr><td colspan="3" align="center" class="ArticleLargeText">Chart theme&nbsp;<SELECT SIZE="1" ONCHANGE="SetChartType()" ID="MSELECT1" CLASS="PageNumber"><OPTION VALUE="1">Cool blues</OPTION><OPTION VALUE="2">Multicolored</OPTION></SELECT></td></tr>'; HTML = HTML + '<tr><td colspan="3" height="5"></td></tr><tr><td colspan="3" align="center" class="ArticleLargeText">Include \'Unknowns\' in charts<INPUT TYPE="CHECKBOX" ID="IncludeUnknowns" onClick="IUClick()"></td></tr>'; HTML = HTML + '<tr><td colspan="3" height="5"></td></tr><tr><td colspan="3" align="center" class="ArticleLargeText">Animate charts<INPUT TYPE="CHECKBOX" ID="AnimateCharts" onClick="ACClick()"></td></tr>';
 HTML = HTML + '<tr><td colspan="3" height="5"></td></tr><tr><td colspan="3" align="center"><br><INPUT TYPE="BUTTON" onClick="WriteCookie();HideMessage();RefreshDisplay(true,true,true)" STYLE="width:100px" VALUE="OK">&nbsp;<INPUT TYPE="BUTTON" onClick="HideMessage()" STYLE="width:100px" VALUE="Cancel"></td></tr><tr height="10"><td></td></tr></table></td></tr></table></DIV>'; myGetElementById("Message").innerHTML = HTML;  myGetElementById("MSELECT1").value = DP_ChartTheme; UpdateCheckBox("IncludeUnknowns", GB_ChartIncludeUnknown); UpdateCheckBox("AnimateCharts", GB_AnimateCharts);  if (! Mozilla) myGetElementById("Mask").style.filter = 'alpha(opacity=20)'; else myGetElementById("Mask").style.opacity = '0.2'; myGetElementById("Mask").style.width = MaxWidth() + 'px'; myGetElementById("Mask").style.height = MaxHeight() + 'px'; myGetElementById("Mask").style.top = "0px"; myGetElementById("Mask").style.left = "0px"; myGetElementById("Mask").style.display = "block"; SelectBoxes(true); FusionCharts(true); HideMenu("All");
 Buttons("none"); myGetElementById("Chart").style.display = "none"; myGetElementById("Message").style.display = ""; }  function SetChartType() { DP_ChartTheme = myGetElementById("MSELECT1").value; }  function UpdateCopyright() { myGetElementById("CopyrightSpan").innerHTML = Copyright; }  /* ------------------------------------------------------------------------------------------------- */  function WritePageArguments(PageArguments) { var	expireDate3;  if (window.navigator.cookieEnabled) { expireDate3 = new Date; expireDate3.setMinutes(expireDate3.getMinutes()+5); document.cookie = "GB_PA=" + PageArguments + "; path=/; expires=" + expireDate3.toGMTString(); } }  function ReadPageArguments() { var	expireDate3, Count; var Items = new Array();  if (window.navigator.cookieEnabled) { GB_PageArguments = GetCookieValue("GB_PA", ""); GB_PageArguments = GB_PageArguments.replace(/<<SC>>/g, "&#44;"); if (GB_PageArguments.indexOf(SH_Report) != -1) { expireDate3 = new Date; expireDate3.setMinutes(expireDate3.getMinutes()-1);
 document.cookie = "GB_PA=" + GB_PageArguments + "; path=/; expires=" + expireDate3.toGMTString(); Items = GB_PageArguments.split("|"); if (Items.length >= 2) DP_CurrentView = Items[1]; if (Items.length >= 3) { switch (Items[0]) { case "Master Hardware" : for (Count=2; Count<(Items.length-1); Count=Count+2) { if (Items[Count] == "MAN") DP_Manufacturer = Items[Count+1]; if (Items[Count] == "SC") DP_SortColumn = eval(Items[Count+1]); if (Items[Count] == "SEA") DP_StartSearch = Items[Count+1]; } DP_CurrentPage = 0; break; case "Master Software" : for (Count=2; Count<(Items.length-1); Count=Count+2) { if (Items[Count] == "SC") DP_SortColumn = eval(Items[Count+1]); if (Items[Count] == "SEA") DP_StartSearch = Items[Count+1]; } DP_CurrentPage = 0; break; } } Items.length = 0; } else GB_PageArguments = ""; } }  function NavigateToPage(PageHTML, PageName, PageView, PageArgument) { WritePageArguments(PageName + "|" + PageView + "|" + PageArgument); window.location.href = PageHTML; } 
 /* ------------------------------------------------------------------------------------------------- */  function CheckNavigate(MessageText, SubText, URL) { var	HTML;  HTML = '<DIV STYLE="position: absolute; left: ' + ((DP_TableWidth / 2) - 200) + 'px; top: ' + (window.document.body.scrollTop + 100) + 'px; height: 120px; width: 400px; padding: 1em; z-index:201">';
 HTML = HTML + '<table width="400" border="0" cellpadding="2" cellspacing="0" bgcolor="#6699CC"><tr><td><table width="400" border="0" cellpadding="2" cellspacing="0" bgcolor="#FFFFFF"><tr><td colspan="3"><img src="' + DP_ImagePath + '/Assets/9002.jpg"></td></tr><tr><td colspan="3" align="center"><B>' + MessageText + '</B></td></tr><tr height="10"><td></td><tr><td colspan="3" align="center"><span class="PageNumber">' + SubText + '</span></td></tr><tr height="10"><td></td></tr><tr><td colspan="3" align="center"><INPUT TYPE="BUTTON" onClick="DoneCheckNavigate(\'Yes\',\'' + URL +'\')" STYLE="width:50px" VALUE="OK">&nbsp;&nbsp;<INPUT TYPE="BUTTON" onClick="DoneCheckNavigate(\'No\',\'\')" STYLE="width:50px" VALUE="Cancel"></td></tr><tr height="10"><td></td></table></td></tr></table></DIV>'; myGetElementById("Message").innerHTML = HTML;  if (! Mozilla) myGetElementById("Mask").style.filter = 'alpha(opacity=20)'; else myGetElementById("Mask").style.opacity = '0.2'; myGetElementById("Mask").style.display = "block";
 myGetElementById("Mask").style.width = MaxWidth() + 'px'; myGetElementById("Mask").style.height = MaxHeight() + 'px'; myGetElementById("Mask").style.top = "0px"; myGetElementById("Mask").style.left = "0px"; SelectBoxes(true); FusionCharts(true); HideMenu("All"); myGetElementById("Chart").style.display = "none"; myGetElementById("Message").style.display = ""; }  function DoneCheckNavigate(Navigate, URL) { if (Navigate != "Yes") { if (URL == "Function:DoHardwareUpdate") return(false); SelectBoxes(false); FusionCharts(false); ShowMenu(); myGetElementById("Message").style.display = "none"; myGetElementById("Mask").style.display = "none"; if ((SH_ViewArray[DP_CurrentViewNumber].ViewSupportCharts) && (ChartAvailable())) ShowChart(false, "Chart", 150, 150, "Vertical", 10); if (myGetElementById("Search")) { if (myGetElementById("Search").value != "") myGetElementById("Search").select(); } } else { if (URL == "Function:DoHardwareUpdate") { myGetElementById("Message").style.display = "none"; myGetElementById("Mask").style.display = "none";
 DoHardwareUpdate(); return(true); } window.location.href = URL; } }  /* ------------------------------------------------------------------------------------------------- CSV functions */  var SaveHTML;  function CSVExport() { var Count, Count2, ColumnNumber; var CSVData = ""; var CSVLine = ""; var DataItem = ""; var HTML = "", ItemCount;  SaveHTML = myGetElementById("Title").innerHTML;  HideData(); setTimeout("CSVExport2()", 500); }  function CSVExport2() { myGetElementById("Title").innerHTML = '<img src="' + DP_ImagePath + '/Assets/9009.jpg">';  for (Count=0; Count<SH_ViewArray[DP_CurrentViewNumber].ViewFields.length; Count++) { if ((ColumnNumber = GetColumnNumber(SH_ViewArray[DP_CurrentViewNumber].ViewFields[Count])) != -1) { if (Count == 0) CSVLine = SH_FieldArray[ColumnNumber].FieldName; else CSVLine = CSVLine + ',' + SH_FieldArray[ColumnNumber].FieldName; } } CSVData = CSVLine + '<br>'; ItemCount = 0; for (Count=0; (Count < SH_ItemCount); Count++) { if (SH_ItemArray[Count].Flags[0]) { for (Count2=0; Count2<DP_Columns.length; Count2++) {
 if (SH_FieldArray[DP_Columns[Count2]].FieldType == 2) DataItem = AsciiDateTime(SH_ItemArray[Count].Field[DP_Columns[Count2]]); else DataItem = SH_ItemArray[Count].Field[DP_Columns[Count2]] + ""; DataItem = DataItem.replace(/&#44;/g, ""); DataItem = DataItem.replace(/,/g, ""); if (Count2 == 0) CSVLine = DataItem; else CSVLine = CSVLine + ',' + DataItem; } CSVData = CSVData + CSVLine + '<br>'; ItemCount++; } } 
 myGetElementById("Message").innerHTML = '<table width="767" cellpadding="0" cellspacing="0"><tr><td width="45%" valign="top"><span id="CSV_LHS" class="ArticleText BlackText"></span></td><td>&nbsp;</td><td width="50%" valign="top"><table><tr><td class="ArticleHeading">systemhound Data (' + ItemCount + ' records)</td></tr><tr><td class="ArticleHeading">Copy and paste this column into your spreadsheet</td></tr><tr><td><table><tr><td><img src="' + DP_ImagePath + '/Assets/5038.jpg"></td><td class="ArticleFooter" valign="bottom">start</td></tr></table></span><br><br><span id="CSV_RHS"></span><TEXTAREA STYLE="display:none;" ID="holdtext"></TEXTAREA></td></tr></table><span style="position:absolute;top:40px;left:10px"><img src="' + DP_ImagePath + '/Assets/5036.jpg" STYLE="CURSOR:pointer" onClick="DoneCSV();"></span>'; myGetElementById("CSV_RHS").innerHTML = CSVData + '<br><table><tr><td><img src="' + DP_ImagePath + '/Assets/5039.jpg"></td><td class="ArticleFooter" valign="top">end</td></tr></table>';
 HTML = '<span class="ArticleHeading">Instructions for use<br><br></span><span class="ArticleText">The data in the right hand column of this page represents the contents of the systemhound data for all pages of the current <i>"' + SH_Report + '"</i> view.<br><br>'; HTML = HTML + 'If you want to change the selection you should return to the report page and change the filtering options shown at the bottom of the report before clicking the &quot;Export to CSV&quot; button again.<br><br>'; if ((! myGetElementById("CSV_RHS").innerText) || (! myGetElementById("holdtext").createTextRange)) { myGetElementById("CSV_RHS").UNSELECTABLE = "off"; HTML = HTML + 'Once you are happy with the selection you should select all the data then copy and paste it into a spreadsheet program such as Microsoft Excel. <br><br>Instructions for Excel users can be found below.<br><br></span><center><BUTTON class="PageNumber" STYLE="width:120px;background-color: #F0F0F0" onClick="DoneCSV();">Return to report</BUTTON>';
 HTML = HTML + '<br><br><span class="ArticleHeading">Microsoft Excel instructions (Mozilla)</span><br><br><table cellpadding="2" width="100%" class="BlueText"><tr><tr><td valign="top">1.</td><td>Start Microsoft Excel.</td></tr><td valign="top">2.</td><td>Select and Copy the data by highlighting the records shown opposite and pressing Ctrl+C.</td></tr><tr><td></td><td><span class="ArticleFooter BlueText">Note: you will need to scroll the page while selecting for large datasets.</span></td></tr>'; } else { myGetElementById("CSV_RHS").UNSELECTABLE = "on";
 HTML = HTML + 'Once you are happy with the selection you should click the "Copy to clipboard" button and paste the data into a spreadsheet program such as Microsoft Excel.<br><br>Instructions for Excel users can be found below.<br><br></span><center><BUTTON class="PageNumber" STYLE="width:120px;background-color: #F0F0F0" onClick="DoneCSV();">Return to report</BUTTON>&nbsp;<BUTTON class="PageNumber" STYLE="width:120px;background-color: #F0F0F0" onClick="ClipBoard();">Copy to Clipboard</BUTTON></center>'; HTML = HTML + '<br><br><span class="ArticleHeading">Microsoft Excel instructions (Internet Explorer)</span><br><br><table width="100%" class="BlueText"><tr><tr><td valign="top">1.</td><td>Start Microsoft Excel.</td></tr><td valign="top">2.</td><td>Copy the data by clicking the "Copy to Clipboard" button (above)</td></tr><tr>'; }
 HTML = HTML + '<tr><td valign="top">3.</td><td>In Excel, right click on cell A1 and select "Paste" from the pop-up context menu.</td></tr><tr><td></td><td align="center"><img src="' + DP_ImagePath + '/Assets/5031.jpg"><br><span class="ArticleFooter">Pasting the data into Excel</span></td></tr><tr><td valign="top">4.</td><td>Now that the systemhound data has been pasted into the Excel sheet you can start to split the data into columns by selecting "Text to Columns" from the "Data" menu.</td></tr><tr><td></td><td align="center"><img src="' + DP_ImagePath + '/Assets/5032.jpg"><br><span class="ArticleFooter">Start the "Text to Columns" process</span></td></tr><tr><td valign="top">5.</td><td>Make sure that the "Original data type" option is set to "Delimited" and click "Next".</td></tr><tr><td></td><td align="center"><img src="' + DP_ImagePath + '/Assets/5033.jpg"><br><span class="ArticleFooter">Set the "Delimited" option</span></td></tr><tr><td valign="top">6.</td><td>Make sure that only the "Comma" delimiter option is ticked and click "Finish".</td></tr><tr><td></td><td align="center"><img src="' + DP_ImagePath + '/Assets/5034.jpg"><br><span class="ArticleFooter">Select "Comma" as the delimiter</span></td></tr></table><br><span class="BlueText">The systemhound data will be imported into the spreadsheet and will be ready for your customisation and reporting.</span>';
  if (GB_Feedback) HTML = HTML + FeedbackButton("CSV");  myGetElementById("CSV_LHS").innerHTML = HTML; myGetElementById("SHLogo").style.display = ""; myGetElementById("Title").style.display = ""; myGetElementById("Message").style.display = ""; myGetElementById("PleaseWait").style.display = "none"; }  function ClipBoard() { var Span = myGetElementById("CSV_RHS");  myGetElementById("holdtext").innerText = Span.innerText; Copied = myGetElementById("holdtext").createTextRange(); Copied.execCommand("Copy"); }  function DoneCSV() { myGetElementById("Title").innerHTML = SaveHTML; myGetElementById("Message").style.display = "none"; if (ChartAvailable()) if (SH_ViewArray[DP_CurrentViewNumber].ViewSupportCharts) ShowChart(false, "Chart", 150, 150, "Vertical", 10); ShowData(); }  function CSVButton() { if (! GB_MaintenanceMode) { if (SH_ViewArray[DP_CurrentViewNumber].ViewWide) HTML = '<span style="position:absolute;top:99px;left:981px;CURSOR:pointer">'; else HTML = '<span style="position:absolute;top:99px;left:756px;CURSOR:pointer">';
 HTML = HTML + '<img src="' + DP_ImagePath + '/Assets/5035.jpg" id="CSV" onClick="CSVExport()" title="Export the report to CSV"></span>'; } return(HTML); }  /* ------------------------------------------------------------------------------------------------- Feedback functions */  function FeedbackButton(Optional) { if (! Optional) Optional = "";  return('<span id="FeedbackSpan" style="position:absolute;top:12px;left:200px;z-index:9999"><input type="Button" value="Comment on this page" STYLE="width:140px;background-color:#669D75;CURSOR:pointer" class="WhiteText" title="Click here to provide feedback on this page" onClick="FeedbackPage(\'' + Optional + '\')"></span>'); }  function FeedbackPage(Optional) { var PageTitle;  if (Optional != "") PageTitle = document.title + " (" + Optional + ")"; else PageTitle = document.title; 
 Argument = "href=" + window.location.href + "&title=" + PageTitle + " (Version " + ProductVersion + ")&cookieEnabled=" + window.navigator.cookieEnabled + "&appName=" + window.navigator.appName + "&appVersion=" + window.navigator.appVersion + "&appCodeName=" + window.navigator.appCodeName; if (window.navigator.language) lang = window.navigator.language; else if (window.navigator.userLanguage) lang = window.navigator.userLanguage; Argument = Argument + "&language=" + lang + "&platform=" + window.navigator.platform + "&product=" + window.navigator.product; if (Mozilla) { CW = window.innerWidth; CH = window.innerHeight; } else { CW = document.body.clientWidth; CH = document.body.clientHeight; } Argument = Argument + "&innerHeight=" + CH + "&innerWidth=" + CW + "&width=" + window.screen.width + "&height=" + window.screen.height + "&FlashLoaded=" + is_Flash + "&FlashVersion=" + is_FlashVersion; Parameters = ""; if (document.cookie) Parameters = document.cookie;
 Argument = Argument + "&Parameters=" + Parameters + "&SupportEmail=" + SupportEmail + "&SupportName=" + SupportName;  window.open(ExternalLink5 + '?' + Argument); }  /* ------------------------------------------------------------------------------------------------- */  function SetwidthButton(Size) { return('<span id="SetwidthSpan" style="position:absolute;top:102px;left:20px;z-index:9999;CURSOR:pointer"><img src="' + DP_ImagePath + '/Assets/5040.png" title="Click here set the width of the browser to fit the report" onClick="SetwidthClick(' + Size + ')"></span>'); }  function SetwidthClick(Size) { var Width;  if (Size == 0) { Width = DP_TableWidth + 60; if ((SH_ViewArray[DP_CurrentViewNumber].ViewSupportCharts) && (ChartAvailable())) Width = Width + 165; } else Width = Size;  if (Width > screen.width) Width = screen.width;  window.resizeTo(Width, screen.height); window.moveTo((screen.width - Width) / 2, 0); }  function ShowColumn() { var	ColumnName, ViewName, FieldNumber;  ColumnName = myGetElementById("SHOWCOL").value;
 if (((ViewName = GetViewWithColumn(ColumnName)) != "") && ((FieldNumber = GetFieldNumber(ColumnName)) != -1)) { DP_CurrentView = ViewName; if ((CurrentView = GetViewNumber(DP_CurrentView)) != -1) { DP_SortColumn = FieldNumber; InitialiseSortDirection(DP_SortColumn); ResetPage(); HideData(); setTimeout("RefreshDisplay(true, true, true)", 500); } } }  function GetViewWithColumn(ColumnName) { var	Count;  for (Count=0; Count<SH_ViewArray.length; Count++) { for (Count2=0; Count2<SH_ViewArray[Count].ViewFields.length; Count2++) { if (SH_ViewArray[Count].ViewFields[Count2] == ColumnName) return(SH_ViewArray[Count].ViewName); } } return(""); }  function GetFieldNumber(ColumnName) { var	Count;  for (Count=0; Count<SH_FieldArray.length; Count++) { if (SH_FieldArray[Count].FieldName == ColumnName) return(Count); } return(-1); }