private static string CreateHTMLTableString(DataObject dobj)
        {
            if (!XML.HtmlEnabled || !dobj.DataAvailable)
            {
                return(string.Empty);
            }

            StringBuilder sb = new StringBuilder();

            sb.Clear();



            List <string> capabaleItems = DataObjectCategory.GetCapableItems(dobj.Protocol);

            sb.AppendLine("</br><h3>" + HttpUtility.HtmlEncode(dobj.Name) + "</h3>");
            sb.AppendLine("  <table> ");
            sb.AppendLine("  <tr>");
            sb.AppendLine("    <th>" + HttpUtility.HtmlEncode("Datum und Uhrzeit") + "</th>");
            foreach (string s in capabaleItems)
            {
                sb.AppendLine("    <th>" + HttpUtility.HtmlEncode(s) + "</th>");
            }
            sb.AppendLine("    <th>" + HttpUtility.HtmlEncode("Zusatz-Info") + "</th>");
            sb.AppendLine("  </tr>");

            foreach (string dt in dobj.GetLogTimings())
            {
                sb.AppendLine("  <tr>");
                sb.AppendLine("    <td>" + dt + "</td>");

                foreach (string s in capabaleItems)
                {
                    sb.AppendLine("    <td>" + HttpUtility.HtmlEncode(dobj.GetLogItem(dt, s) + DataObjectCategory.GetSensorValueUnit(s)) + "</td>");
                }

                sb.AppendLine("    <td>" + HttpUtility.HtmlEncode(dobj.AdditionalInformation) + "</td>");
                sb.AppendLine("  </tr>");
            }

            sb.AppendLine("  </table> ");
            sb.AppendLine("</br>");

            return(sb.ToString());
        }
        private static string CreateTopOfHtml(DataObject dobj)
        {
            if (!XML.HtmlEnabled || !dobj.DataAvailable)
            {
                return(string.Empty);
            }

            StringBuilder sb = new StringBuilder();

            sb.Clear();

            List <string> capabaleItems = DataObjectCategory.GetCapableItems(dobj.Protocol);

            sb.AppendLine("</br><h3>"
                          + HttpUtility.HtmlEncode("Sensor: " + dobj.Name)
                          + "</h3>");

            sb.AppendLine("<table>");
            sb.AppendLine("  <tr>");
            sb.AppendLine("		<th>Bezeichnung</th>");
            sb.AppendLine("		<th>Wert</th>");
            sb.AppendLine("  </tr>");

            foreach (string s in capabaleItems)
            {
                sb.AppendLine("<tr>");
                sb.AppendLine("<td>" + HttpUtility.HtmlEncode(s) + "</td><td>" + GetData(dobj, s) + "</td>");
                sb.AppendLine("</tr>");
            }

            sb.AppendLine("</table>");
            sb.AppendLine(HttpUtility.HtmlEncode("Zuletzt aktualisiert: "
                                                 + dobj.GetLastUpdatedFormatted())
                          + "</br>");
            return(sb.ToString());
        }