<%@ page language="C#" autoeventwireup="true" inherits="Forms_Dashboard_SLD, App_Web_azu0ludn" enableeventvalidation="false" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/Notification_List.ascx" TagPrefix="uc3" TagName="NotificationsList" %>
<%@ Register Src="~/UserControls/New_Header.ascx" TagName="Header" TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/New_Footer.ascx" TagName="Footer" TagPrefix="uc2" %>
<%@ Register Assembly="DevExpress.Web.v14.2" Namespace="DevExpress.Web" TagPrefix="dxw" %>
<%@ Register Src="~/UserControls/New_Footer_White.ascx" TagPrefix="uc1" TagName="New_Footer_White" %>


<!DOCTYPE html>
<html lang="en">
<head id="Head1" runat="server">
    <title>tSense-IoT Dashboard</title>
    <meta content="charset=utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <link href="../css/Monitor_css/Bootstrap-toggle.min.css" rel="stylesheet" />
    <link href="../css/Monitor_css/bootstrap.min.css" rel="stylesheet">
    <link href="../css/Monitor_css/css-chart.css" rel="stylesheet">
    <link href="../css/Monitor_css/morris.css" rel="stylesheet">
    <link href="../css/Monitor_css/style.css" rel="stylesheet">

    <link id="reset" runat="server" href="../css/reset.css" rel="stylesheet" type="text/css" />
    <link id="dropdown" runat="server" href="../css/dropdown.css" rel="stylesheet" type="text/css" />
    <link id="stylesheet2" runat="server" href="../css/stylesheet2.css" rel="stylesheet" type="text/css" />
    <link id="style" runat="server" href="../css/style.css" rel="stylesheet" type="text/css" />
    <link id="jcarousel" runat="server" rel="stylesheet" type="text/css" href="../css/jquery.jcarousel.css" />
    <link id="skin" runat="server" rel="stylesheet" type="text/css" href="../css/skin.css" />
    <link href="../css/CustomeAlert/demos.css" rel="stylesheet" type="text/css" />
    <link href="../css/CustomeAlert/themes/jquery.ui.all.css" rel="stylesheet" type="text/css" />
    <link href="../css/Monitor_css/Togglesswitch.css" rel="stylesheet" />

    <link id="GridView" type="text/css" href="~/App_Themes/Office2003Blue/GridView/grid.css" rel="stylesheet" />
    <link id="Editors" type="text/css" href="~/App_Themes/Office2003Blue/Editors/styles.css" rel="stylesheet" />
    <link rel="SHORTCUT ICON" href="../images/favicon.ico" />

    <link id="BootStrapCss" href="../css/bootstrap.css" runat="server" rel="stylesheet" type="text/css" />
    <link id="mainstyle" runat="server" href="../css/mainstyle.css" rel="stylesheet" type="text/css" />
    <link rel="icon" href="../NewDesign/img/favicon.png" type="image/x-icon">
    <%--<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700,900" rel="stylesheet">--%>
    <link href="../NewDesign/css/bootstrap.css" rel="stylesheet" />
    <link href="../NewDesign/css/font-awesome.css" rel="stylesheet" />
    <link href="../NewDesign/css/responsive.css" rel="stylesheet" />
    <link href="../NewDesign/css/style.css" rel="stylesheet" />
    <link href="../NewDesign/font-awesome-4.7.0/css/font-awesome.css" rel="stylesheet" />
    <link href="../NewDesign/font-awesome-4.7.0/css/font-awesome.min.css" rel="stylesheet" />
    <link href="../fontawesome-free-5.10.1-web/css/all.min.css" rel="stylesheet" />
    <script src="../js/Monitor_js/jquery.min.js" type="text/javascript"></script>
    <script src="../js/Monitor_js/popper.min.js" type="text/javascript"></script>
    <script src="../js/Monitor_js/bootstrap.min.js" type="text/javascript"></script>
    <script src="../js/Monitor_js/custom.min.js" type="text/javascript"></script>
    <%--<script src="../js/Monitor_js/gauge.min.js" type="text/javascript"></script>--%>
    <script src="../js/Monitor_js/morris.js" type="text/javascript"></script>
    <script src="../js/Monitor_js/perfect-scrollbar.jquery.min.js" type="text/javascript"></script>
    <script src="../js/Monitor_js/raphael-min.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/jquery.min.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/jquery-ui-1.10.3.custom.min.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/jquery-ui-1.10.3.custom.js" type="text/javascript"></script>
    <script src="../js/CustomAlert/CustomAlert.js" type="text/javascript"></script>
    <script src="../js/GetMonitorData.js"></script>
    <script src="../js/Monitor_js/Temp.js"></script>
    <%--<script src="../js/CanvasChart.js"></script>--%>


    <script type="text/javascript">
    </script>
    <script language="javascript" type="text/javascript">
        function HidePopUp() {
            if ($find('mpeMapProgressIndicator') != undefined) {
                $find('mpeMapProgressIndicator').hide();
            }
        }
        function ShowPopUp() {
            if ($find('mpeMapProgressIndicator') != undefined) {
                $find('mpeMapProgressIndicator').show();
            }
        }
    </script>


    <script>
        function LoadMoniterData() {
            if (document.getElementById("hdnuserID") != null) {
                var uservalue = document.getElementById("hdnuserID").value;
                var DeviceId = document.getElementById("hdnDeviceId").value;
                var DeviceType = document.getElementById("hdnDevieType").value;
                //GetMonitorData(DeviceId, uservalue, DeviceType);
                GenMainSLDData(DeviceId, uservalue);
                LoadChartControl();
            }
        }
        function LoadChartControl() {
            //ChartGauFreqgauge.value = document.getElementById("hdnFrequency").value;
            //ChartGauGenLinetoNeutral.value = document.getElementById("hdnLNVolt").value;
            //ChartGauGenLinetoLine.value = document.getElementById("hdnLLVolt").value;
            //ChartGauSpeedgauge.value = document.getElementById("hdnSpeed").value;
            //ChartBatteryCharger.value = document.getElementById("hdnBatteryCharger").value;
            //ChartGauBatteryVoltage.value = document.getElementById("hdnBatteryVolt").value;
            //ChartGauChargeAlternator.value = document.getElementById("hdnChrgAlter").value;
            //ChartGauCoolantTemperature.value = document.getElementById("hdnCoolTemp").value;
            //ChartGauOilTemperature.value = document.getElementById("hdnOilTemp").value;
            //ChartGauOilPressure.value = (parseInt(document.getElementById("hdnOilPres").value) / 100);
            //ChartGauFuelLevel.value = document.getElementById("hdnFuelLvl").value;
        }


        window.onload = function (e) {
            LoadMoniterData();
        }

    </script>
    <script src="../js/wow.min.js"></script>
    <style type="text/css">
        .textStyle {
            position: absolute;
            right: 0;
            bottom: 0;
            padding-right: 10px !important;
            color: white;
            margin: 0 !important;
        }

        input[type=radio], input[type=checkbox] {
            display: none;
        }

            input[type=radio] + label, input[type=checkbox] + label {
                display: inline-block;
                /*margin: -2px;*/
                padding: 4px 12px;
                margin-bottom: 0;
                font-size: 12px;
                line-height: 22px;
                color: #1267ba;
                text-align: center;
                /*text-shadow: 0 1px 1px rgba(255,255,255,0.75);*/
                vertical-align: middle;
                cursor: pointer;
                background-color: #f5f5f5;
                background-image: -moz-linear-gradient(top,#fff,#e6e6e6);
                background-image: -webkit-gradient(linear,0 0,0 100%,from(#fff),to(#e6e6e6));
                background-image: -webkit-linear-gradient(top,#fff,#e6e6e6);
                background-image: -o-linear-gradient(top,#fff,#e6e6e6);
                background-image: linear-gradient(to bottom,#fff,#e6e6e6);
                background-repeat: repeat-x;
                border: 1px solid #ccc;
                border-color: #e6e6e6 #e6e6e6 #bfbfbf;
                border-color: rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);
                border-bottom-color: #b3b3b3;
                filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff',endColorstr='#ffe6e6e6',GradientType=0);
                filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
                -webkit-box-shadow: inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);
                -moz-box-shadow: inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);
                box-shadow: inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);
            }

            input[type=radio]:checked + label, input[type=checkbox]:checked + label {
                background-image: none;
                outline: 0;
                -webkit-box-shadow: inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);
                -moz-box-shadow: inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);
                box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.29), 0 1px 2px rgba(0, 0, 0, 0);
                background-color: #1450a4;
                color: white;
            }

        .fa-spingreen {
            -webkit-animation: fa-spin 2s infinite linear;
            animation: fa-spin 1s infinite linear;
        }

        .fa-spinOrange {
            -webkit-animation: fa-spin 2s infinite linear;
            animation: fa-spin 2s infinite linear;
        }

        .cf1_v {
            border: 1px solid #A39EA2;
            background: #404040;
            border-radius: 10px;
            height: 85px;
            padding: 10px 1px;
            float: left;
            width: 35%;
            margin-bottom: 30px;
            text-align: center;
            margin-right: 1.33%;
        }

        text {
            color: white !important;
        }

        th {
            text-align: center;
        }

        div.infoPanel {
            margin: 5px;
            padding: 5px;
            padding-top: 0px;
            /*border: 1px solid #111;*/
            -moz-border-radius: 5px;
            /*border-radius: 5px;*/
            display: block;
            text-shadow: 0px 1px 0px #000;
            /*background-color: #444444 !important;
            background: linear-gradient(#696969, #363636) !important;*/
        }
    </style>
    <style type="text/css">
        .bg-light {
            background-color: #f8f9fa !important;
            box-shadow: 0 2px 5px 0 rgba(0,0,0,0.16),0 2px 10px 0 rgba(0,0,0,0.12);
        }

        a.bg-light:focus, a.bg-light:hover, button.bg-light:focus, button.bg-light:hover {
            background-color: #dae0e5 !important;
        }

        .card-body {
            -ms-flex: 1 1 auto;
            flex: 1 1 auto;
            padding: 1.25rem;
        }

        .btn-circle {
            width: 30px;
            height: 30px;
            padding: 6px 0px;
            border-radius: 15px;
            text-align: center;
            font-size: 15px;
            line-height: 0.42857;
        }

        .icons {
            float: left;
            padding: 6px 0px !important;
            margin-top: 20px !important;
        }

            .icons a {
                padding: 4px 5px !important;
            }

        .col-md-1 {
            width: 7.333333% !important;
        }

        .col-xs-3_L {
            width: 25%;
            float: left;
            margin-left: 0%;
        }

        .col-xs-7_L {
            width: 58.33333333%;
            float: left;
            color: white;
            text-align: left;
            margin-left: 10%;
        }
    </style>
    <style>
        .dropbtn {
            background-color: #4e4c4c;
            color: white;
            padding: 16px;
            font-size: 16px;
            border: none;
        }

        .dropdown {
            position: relative;
            display: inline-block;
        }

        .dropdown-content {
            display: block;
            position: inherit;
            background-color: #4e4c4c;
            min-width: 130px;
            box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
            z-index: 1;
        }

            .dropdown-content a {
                color: black;
                padding: 12px 16px;
                text-decoration: none;
                display: block;
            }

                .dropdown-content a:hover {
                    background-color: #ddd;
                }

        .dropdown:hover .dropdown-content {
            display: block;
        }

        .dropdown:hover .dropbtn {
            background-color: #3e8e41;
        }
    </style>
</head>
<body>
    <div class="preloader"></div>
    <div class="page-wrapper" style="background: #404040 !important">
        <form id="form1" runat="server">
            <asp:HiddenField ID="hdnGuid" runat="server" />
            <asp:Panel ID="pnlLoading" runat="server" Style="display: none;" Font-Bold="true">
            </asp:Panel>
            <cc1:ModalPopupExtender ID="ModalProcess" runat="server" TargetControlID="Button1"
                PopupControlID="pnlLoading" Drag="true" DropShadow="true" X="400" Y="500" BackgroundCssClass="modalBackground">
            </cc1:ModalPopupExtender>
            <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true"
                AsyncPostBackTimeout="600" EnablePageMethods="true">
            </asp:ScriptManager>
            <uc1:Header ID="ucHeader" runat="server" />
            <div class="vlive-filter">
                <asp:UpdatePanel ID="UpdMap" runat="server">
                    <ContentTemplate>
                        <asp:HiddenField ID="hdnTemp" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnSpeed" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnBatteryCharger" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnBatteryVolt" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnFrequency" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnLNVolt" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnLLVolt" runat="server" Value="0" />

                        <asp:HiddenField ID="S2_hdnFrequency" runat="server" Value="0" />
                        <asp:HiddenField ID="S2_hdnLNVolt" runat="server" Value="0" />
                        <asp:HiddenField ID="S2_hdnLLVolt" runat="server" Value="0" />

                        <asp:HiddenField ID="hdnPreTemp" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnPreSpeed" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnPreBatteryVolt" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnPreFrequency" runat="server" Value="0" />

                        <asp:HiddenField ID="hdnChrgAlter" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnCoolTemp" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnOilTemp" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnOilPres" runat="server" Value="0" />
                        <asp:HiddenField ID="hdnFuelLvl" runat="server" Value="0" />

                        <asp:HiddenField ID="hdnuserID" runat="server" />
                        <asp:HiddenField ID="hdnDeviceId" runat="server" />
                        <asp:HiddenField ID="hdnDevieType" runat="server" />
                        <asp:HiddenField ID="hdnDigit_IP" runat="server" />
                        <asp:HiddenField ID="hdnDigit_OP" runat="server" />
                        <div class="vlive-reports-section">
                            <div class="container-fluid">
                                <div class="row clearfix">
                                    <div class="col-sm-12">
                                        <div style="display: none">
                                            <div class="col-ks-2_5" runat="server" style="display: none;" id="divCustomer">
                                                <div>
                                                    <label for="exampleFormControlSelect1">
                                                        <asp:Label runat="server" ID="Label2" Text="Customer"></asp:Label></label>
                                                    <dxw:ASPxComboBox ID="ddlCustomer" runat="server" ValueType="System.Int32" CssClass="form-control"
                                                        ClientInstanceName="ddlCustomer" SelectedIndex="0" OnSelectedIndexChanged="ddlCustomer_SelectedIndexChanged"
                                                        EnableIncrementalFiltering="true" AutoPostBack="true" EnableTheming="true" Theme="Office2003Blue"
                                                        CssFilePath="~/App_Themes/office2003Blue/Editors/styles.css" CssPostfix="office2003_Blue">
                                                        <ClientSideEvents SelectedIndexChanged="function(s, e) { ShowPopUp(); }" />
                                                    </dxw:ASPxComboBox>
                                                </div>
                                            </div>
                                            <div class="col-ks-2_5">
                                                <div>
                                                    <label for="exampleFormControlSelect1">
                                                        <asp:Label runat="server" ID="lblFleetCaption" Text=""></asp:Label></label>
                                                    <dxw:ASPxComboBox ID="ddlFleet" runat="server" ValueType="System.Int32" CssClass="form-control"
                                                        ClientInstanceName="ddlFleet" SelectedIndex="0" OnSelectedIndexChanged="ddlFleet_SelectedIndexChanged"
                                                        EnableIncrementalFiltering="true" AutoPostBack="true" EnableTheming="true" Theme="Office2003Blue"
                                                        CssFilePath="~/App_Themes/office2003Blue/Editors/styles.css" CssPostfix="office2003_Blue">
                                                        <ClientSideEvents SelectedIndexChanged="function(s, e) { ShowPopUp(); }" />
                                                    </dxw:ASPxComboBox>
                                                </div>
                                            </div>
                                            <div class="col-ks-2_5">
                                                <div>
                                                    <label for="exampleFormControlSelect1">
                                                        <asp:Label runat="server" ID="lblDevice" Text="Device"></asp:Label></label>
                                                    <dxw:ASPxComboBox ID="ddlEquipment" runat="server" CssClass="form-control"
                                                        ClientInstanceName="ddlEquipment" SelectedIndex="0" OnSelectedIndexChanged="ddlEquipment_SelectedIndexChanged"
                                                        EnableIncrementalFiltering="true" AutoPostBack="true" EnableTheming="true" Theme="Office2003Blue"
                                                        CssFilePath="~/App_Themes/office2003Blue/Editors/styles.css" CssPostfix="office2003_Blue">
                                                        <ClientSideEvents SelectedIndexChanged="function(s, e) { ShowPopUp(); }" />
                                                    </dxw:ASPxComboBox>
                                                </div>
                                            </div>
                                            <div class="col-ks-2">
                                                <div class="col-ks-16 btn-icons">
                                                    <div class="col-ks-4" style="align-content: center">
                                                        <asp:LinkButton ID="ibtnReferesh" runat="server" CssClass="btn btn-danger btn-circle btn-lg"
                                                            ToolTip="Referesh" OnClick="ibtnReferesh_Click" OnClientClick="ShowPopUp();"><i class="fa fa-refresh" aria-hidden="true"></i>
                                                        </asp:LinkButton>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-ks-2_5">
                                            <div class="col-ks-16">
                                                <h4 class="pull-left">
                                                    <asp:Literal ID="ltMonitor" runat="server" Text=""></asp:Literal>
                                                </h4>
                                            </div>
                                        </div>
                                        <div class="col-ks-2_5"></div>
                                        <div class="col-ks-2"></div>
                                        <div class="col-ks-9">
                                            <div class="pull-right">
                                                <asp:UpdatePanel ID="udpfan" runat="server" UpdateMode="Conditional">
                                                    <ContentTemplate>
                                                        <div class="col-ks-10">
                                                            <div class="col-ks-16 btn-icons">
                                                                <asp:LinkButton ID="lbtnShowDashBoard" runat="server" OnClientClick="ShowPopUp();"
                                                                    CssClass="btn btn-primary fa-arrow-left" Text="&nbsp;&nbsp;Back" OnClick="lbtnShowDashBoard_Click" />
                                                            </div>
                                                        </div>
                                                        <div class="col-ks-16 btn-icons ControlHide">
                                                            <asp:RadioButtonList ID="rdblParam" CssClass="radiobtnlst form-controllinebreak" OnSelectedIndexChanged="rdbl_SelectedIndexChanged" runat="server" TabIndex="32" AutoPostBack="true" RepeatDirection="Horizontal" onchange="ShowPopUp();">
                                                                <asp:ListItem Value="0" Text="Generator" Selected="True"></asp:ListItem>
                                                                <asp:ListItem Value="1" Text="Engine"></asp:ListItem>
                                                                <asp:ListItem Value="2" Text="Digital Input"></asp:ListItem>
                                                                <asp:ListItem Value="3" Text="Digital Output"></asp:ListItem>
                                                                <asp:ListItem Value="4" Text="Back"></asp:ListItem>
                                                            </asp:RadioButtonList>
                                                        </div>
                                                    </ContentTemplate>
                                                </asp:UpdatePanel>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <%--Send Command & Last Reported Date--%>
                        <div class="container-fluid ControlHide">
                            <div class="vlive-f-status pull-left">
                                <div class="infoPanel">
                                    <asp:Image ID="imgDevice" runat="server" ImageUrl="~/images/DSE_335.png" Width="125px" Height="100px" />
                                    <table id="Div_details" runat="server" style="float: right; margin-top: 25px;">
                                        <tr>
                                            <td><strong>
                                                <asp:Label ID="Label1" ForeColor="White" runat="server" Text="Device Name:" Visible="true"></asp:Label></strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="lblDeviceName" runat="server" ForeColor="White" Text=""></asp:Label>
                                            </td>
                                        </tr>
                                        <%--<tr>
                                            <td>
                                                <strong>
                                                    <asp:Label ID="lblpagecountcaption" ForeColor="white" runat="server" Text="last reported on:" Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>&nbsp;<asp:Label ID="lblreportedon" runat="server" ForeColor="white" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>--%>
                                        <tr id="tdSupervior" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label3" ForeColor="White" runat="server" Text="Supervisor State: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="lblSupervisorState" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                        <tr id="tdGeneratorrating" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label4" ForeColor="White" runat="server" Text="Generator rating: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="lblGeneratorRating" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                        <tr id="tdBatteryCharger" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label7" ForeColor="White" runat="server" Text="Battery Charger: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="lblBatteryCharger" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                    </table>

                                </div>

                                <%-- <a></a>
                                <a></a>--%>
                            </div>
                            <div class="cf1_V" style="float: left; position: relative; left: 12%; border: none; height: 1%; padding-top: -1%">
                            </div>
                            <div class="vlive-f-status pull-right">
                                <div class="infoPanel">
                                    <asp:Image ID="imgDevice1" runat="server" ImageUrl="~/images/DSE_7410.png" Width="125px" Height="100px" />
                                    <table id="Table1" runat="server" style="float: right; margin-top: 25px;">
                                        <tr>
                                            <td><strong>
                                                <asp:Label ID="Label5" ForeColor="White" runat="server" Text="Device Name:" Visible="true"></asp:Label></strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="lblGenDevName" runat="server" ForeColor="White" Text=""></asp:Label>
                                            </td>
                                        </tr>
                                        <%--<tr>
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label8" ForeColor="white" runat="server" Text="last reported on:" Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>&nbsp;<asp:Label ID="lblGenDevLastReport" runat="server" ForeColor="white" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>--%>
                                        <tr id="Tr1" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label6" ForeColor="White" runat="server" Text="Supervisor State: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="Label9" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                        <tr id="Tr2" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label10" ForeColor="White" runat="server" Text="Generator rating: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="Label11" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                        <tr id="Tr3" runat="server" visible="false">
                                            <td>
                                                <strong>
                                                    <asp:Label ID="Label12" ForeColor="White" runat="server" Text="Battery Charger: " Visible="true"></asp:Label>
                                                </strong>
                                            </td>
                                            <td>
                                                <asp:Label ID="Label13" runat="server" ForeColor="White" Text="" Visible="true"></asp:Label>
                                            </td>
                                        </tr>
                                    </table>

                                </div>
                            </div>
                            <div class="clearfix"></div>
                        </div>
                        <%--<asp:Panel ID="Panel1" runat="server" CssClass="ControlShow">
                            <div id="Div1" runat="server">
                                <div class="vlive-centrifugal-fan">
                                    <div class="clear clearfix"></div>
                                    <div class="cf1" id="divMainValue1" style="padding-top: 0px; width: 20%; height: 37px">
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px;">
                                            <asp:Label ID="lblMainHead" runat="server" Text="ATS"></asp:Label>
                                        </h2>
                                    </div>
                                    <div class="cf1" id="divMainValue2" style="padding-top: 0px; width: 50%; height: 37px; border: none;">                                        
                                    </div>
                                    <div class="cf1" id="divMainValue3" style="padding-top: 0px; width: 20%; height: 37px">
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px;">
                                            <asp:Label ID="Label15" runat="server" Text="GENERATOR"></asp:Label>
                                        </h2>
                                    </div>
                                </div>
                            </div>
                        </asp:Panel>--%>

                        <asp:Panel ID="pnlSLDInfo" runat="server" CssClass="ControlShow">
                            <div id="Div4" runat="server" style="padding-left: 15px;">
                                <div class="vlive-centrifugal-fan">
                                    <div class="clear clearfix"></div>
                                    <div class="cf1" id="divMainValue" style="padding-top: 0px; width: 20%; height: 100%">
                                        <%--<div class="cf1" id="divMainValue1" style="padding-top: 0px; width: 20%; height: 37px">
                                        
                                    </div>--%>
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px; margin-bottom: 5px !important; border-bottom: inherit;">
                                            <asp:Label ID="lblMainHead" runat="server" Text="ATS"></asp:Label>
                                        </h2>
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px; margin-bottom: 5px !important;">
                                            <%--<asp:Label ID="Label11" runat="server" Text="Main"></asp:Label>--%>
                                            <u><a href='#' id="hlnkMainName" style="color: white;">Main</a></u>
                                        </h2>
                                        <div>
                                            <strong>
                                                <asp:Label ID="lblpagecountcaption" ForeColor="white" runat="server" Text="Last reported on:" Visible="true"></asp:Label>
                                            </strong>
                                            <asp:Label ID="lblreportedon" runat="server" ForeColor="white" Text="" Visible="true"></asp:Label>
                                        </div>
                                        <table class="table table-dark" style="margin-bottom: 0px !important">
                                            <%--<thead style="text-align: center;">
                                                <tr>
                                                    <th></th>
                                                    <th style="text-align: center; font-weight: bold;">Volt</th>
                                                </tr>
                                            </thead>--%>
                                            <tr style="text-align: center;">
                                                <td>L-L
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L_L" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L-N
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L_N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Current
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_Current" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Frequency
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_Frequency" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>kW
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_kW" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L1N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L2N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L3-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L3N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-L2(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L1L2" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2-L3(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L2L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-L3(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L1L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L1" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L2" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L3(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Main_L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                        </table>
                                    </div>

                                    <div class="cf1" id="divSLDDiagram" style="padding-top: 0px; width: 50%; height: 330px; border-width: 0px;">
                                        <div class="cf1" id="divSLDDiagramt" style="padding-top: 0px; width: 100%; height: 330px">
                                            <h2 style="border-radius: 9px; border-bottom-left-radius: 0px;">
                                                <asp:Label ID="Label21" runat="server" Text="LOAD"></asp:Label></h2>

                                            <table class="table-dark" style="width: 100%;">

                                                <tr style="text-align: center; height: 100px;">
                                                    <td style="vertical-align: bottom;">
                                                        <img src="#" id="imgMainStatus" runat="server" alt="SLD1">
                                                    </td>
                                                    <td>
                                                        <img src="../Images/SLD_Load.png" id="img2" runat="server" alt="SLD1">
                                                    </td>
                                                    <td style="vertical-align: bottom;">
                                                        <img src="#" id="imgGenStatus" runat="server" alt="SLD1">
                                                    </td>
                                                </tr>
                                                <tr style="text-align: center; height: 10px;">
                                                    <td colspan="3" style="vertical-align: top;">
                                                        <img src="../Images/Main_Gen_Open.png" id="imgDevOpenCloseStatus" runat="server" alt="SLD1">
                                                    </td>
                                                </tr>
                                                <tr style="text-align: center; height: 10px;">
                                                    <td colspan="3" style="vertical-align: top;">
                                                        <table class="table-dark" style="width: 100%;">
                                                            <td style="vertical-align: bottom; text-align: center; width: 25%;"></td>
                                                            <td style="vertical-align: bottom; text-align: center; width: 25%; color: darkgrey;">Mains Breaker</td>
                                                            <td style="vertical-align: bottom; text-align: center; width: 25%; color: darkgrey;">Generator Breaker</td>
                                                            <td style="vertical-align: bottom; text-align: center; width: 25%;"></td>
                                                        </table>
                                                    </td>
                                                </tr>
                                            </table>
                                        </div>
                                        <div class="cf1" id="divSLDDiagram1" style="padding-top: 0px; width: 100%; height: 50px; border-width:0px;">
                                            <table class="table-dark" style="width: 100%;">
                                                <tr style="text-align: left;">
                                                    <div class="col-ks-15_5" style="text-align: right;">
                                                        <div class="dropdown">
                                                            <%--<asp:LinkButton ID="btnLegends" runat="server" CssClass="fa fa-list-ul btn btn-primary" CausesValidation="false" OnClientClick="return false" Text="&nbsp;&nbsp;Legends"></asp:LinkButton>--%>
                                                            <div class="dropdown-content">
                                                                <div class="col-sm-12">
                                                                    <div class="row row-Geozone">

                                                                        <div class="col-xs-7_L">
                                                                            <asp:Label ID="Label19" runat="server" Text="Legends"></asp:Label>
                                                                        </div>
                                                                    </div>
                                                                    <div class="row row-Geozone">
                                                                        <div class="col-xs-3_L">
                                                                            <img src='../images/Device_Shutdown - Copy.png' alt='Shutdown' style='height: 15px; width: 15px' />
                                                                        </div>
                                                                        <div class="col-xs-7_L">
                                                                            <asp:Label ID="Label14" runat="server" Text="Shutdown"></asp:Label>
                                                                        </div>
                                                                    </div>
                                                                    <div class="row row-Geozone">
                                                                        <div class="col-xs-3_L">
                                                                            <img src='../images/Device_Warning.png' alt='Warning' style='height: 15px; width: 15px' />
                                                                        </div>
                                                                        <div class="col-xs-7_L">
                                                                            <asp:Label ID="Label16" runat="server" Text="Warning"></asp:Label>
                                                                        </div>
                                                                    </div>
                                                                    <div class="row row-Geozone">
                                                                        <div class="col-xs-3_L">
                                                                            <img src='../images/Device_Running.png' alt='Running' style='height: 15px; width: 15px' />
                                                                        </div>
                                                                        <div class="col-xs-7_L">
                                                                            <asp:Label ID="Label17" runat="server" Text="Running"></asp:Label>
                                                                        </div>
                                                                    </div>
                                                                    <div class="row row-Geozone">
                                                                        <div class="col-xs-3_L">
                                                                            <img src='../images/Device_Online - Copy.png' alt='Information' style='height: 15px; width: 15px' />
                                                                        </div>
                                                                        <div class="col-xs-7_L">
                                                                            <asp:Label ID="Label18" runat="server" Text="Information"></asp:Label>
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </tr>
                                            </table>
                                        </div>
                                    </div>

                                    <div class="cf1" id="divGenValue" style="padding-top: 0px; width: 20%; height: 100%;">
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px; margin-bottom: 5px !important; border-bottom: inherit;">
                                            <asp:Label ID="Label15" runat="server" Text="GENERATOR"></asp:Label>
                                        </h2>
                                        <h2 style="border-radius: 9px; border-bottom-left-radius: 9px; margin-bottom: 5px !important;">
                                            <%--<asp:Label ID="Label16" runat="server" Text="Generator"></asp:Label>--%>
                                            <%--<asp:LinkButton ID="lnkGenName" runat="server" Text=""
                                                            ToolTip="Referesh" OnClick="lnkGenName_Click" OnClientClick="ShowPopUp();">
                                                        </asp:LinkButton>--%>
                                            <u><a href='#' id="hlnkGenName" style="color: white;">Generator</a></u>
                                        </h2>
                                        <div>
                                            <strong>
                                                <asp:Label ID="Label8" ForeColor="white" runat="server" Text="Last reported on:" Visible="true"></asp:Label>
                                            </strong>
                                            <asp:Label ID="lblGenDevLastReport" runat="server" ForeColor="white" Text="" Visible="true"></asp:Label>
                                        </div>
                                        <table class="table table-dark" style="margin-bottom: 0px !important">
                                            <%--<thead style="text-align: center;">
                                                <tr>
                                                    <th></th>
                                                    <th style="text-align: center; font-weight: bold;">Volt</th>
                                                </tr>
                                            </thead>--%>
                                            <tr style="text-align: center;">
                                                <td>L-L
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L_L" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L-N
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L_N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Current(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_Current" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Frequency(Hz)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_Frequency" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Total Watts(kW)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_kW" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Fuel Level(%)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_FuelLlevel" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>Engine Running Hours
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_EngRunning" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L1N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L2N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L3-N(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L3N" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-L2(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L1L2" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2-L3(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L2L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1-L3(v)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L1L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L1(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L1" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L2(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L2" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                            <tr style="text-align: center;">
                                                <td>L3(A)
                                                </td>
                                                <td>
                                                    <asp:Label runat="server" ID="lblSLD_Gen_L3" Text="0"></asp:Label>
                                                </td>
                                            </tr>
                                        </table>
                                    </div>
                                </div>
                            </div>
                            <asp:Timer ID="tmr1" runat="server" OnTick="tmr1_Tick" Enabled="false">
                            </asp:Timer>
                            <asp:Timer ID="tmrShow" runat="server" OnTick="tmrShow_Tick" Enabled="false">
                            </asp:Timer>
                            <asp:HiddenField ID="hdnRefreshFrequencyValue" runat="server" />
                            <asp:HiddenField ID="hdnRefreshFrequency" runat="server" />
                        </asp:Panel>

                    </ContentTemplate>
                    <Triggers>
                        <asp:AsyncPostBackTrigger ControlID="ibtnReferesh" />
                    </Triggers>
                </asp:UpdatePanel>
            </div>

            <cc1:ModalPopupExtender ID="mpeProgressIndicator" runat="server" PopupControlID="progressPopUp"
                BackgroundCssClass="modalBackground" TargetControlID="btnTesting">
            </cc1:ModalPopupExtender>
            <asp:Button ID="btnTesting" Style="display: none;" runat="server" />
            <asp:Panel ID="progressPopUp" runat="server" CssClass="processMessage" Style="z-index: 10000; display: none;">
                <center>
				<br />
				<img id="imgLoad" runat="server" alt="Please Wait ..." src="../images/47.gif" /><br />
				<br />
				<asp:Label ID="lbl_msg12" Text="Processing... Please Wait..." runat="server" CssClass="specialdisplay"></asp:Label>
				<br />
				<br />
					</center>
            </asp:Panel>
            <asp:Button ID="Button1" runat="server" Style="display: none" />
            <a href="#" id="downloadLink" class="ControlHide">Download the inner html</a>
            <div id="kmlData" class="ControlHide"></div>
            <script lang="javascript" type="text/javascript" src="../js/jquery-1.11.2.min.js"></script>
            <%--<script src="../js/Monitor_js/morris-data.js" type="text/javascript"></script>--%>
            <script lang="javascript" type="text/javascript" src="../js/MapPageScript.js"></script>
            <script lang="javascript" type="text/javascript" src="../js/jquery.jcarousel.min.js"></script>
            <script src="../js/myformvalidations.js" type="text/javascript"></script>
            <script type="text/javascript" src="../js/GridCheckBoxMaintaining.js"></script>
            <script src="../js/Formvalidations.js" type="text/javascript"></script>
            <script src="../js/Monitor_js/bundle.js"></script>
            <%--<script src="../js/CanvasChart.js"></script>--%>
            <script src="../js/CanvasChart.js"></script>
            <script src="../js/Monitor_js/widget-data.js"></script>
        </form>
    </div>
    <uc1:New_Footer_White runat="server" ID="New_Footer_White" />
    <%-- <script>
        function LoadChartControl() {
            //$("#GauFreqgauge").attr("data-value", (document.getEl            var EngRuntime = document.getElementById('lblEngineHrs');
            //nt.getElementById('lblEngineHrs');
            ChartGauFreqgauge.value = document.getElementById("hdnFrequency").value;
            ChartGauGenLinetoNeutral.value = document.getElementById("hdnLNVolt").value;
            ChartGauGenLinetoLine.value = document.getElementById("hdnLLVolt").value;
            ChartGauSpeedgauge.value = document.getElementById("hdnSpeed").value;
            ChartBatteryCharger.value = document.getElementById("hdnBatteryCharger").value;
            ChartGauBatteryVoltage.value = document.getElementById("hdnBatteryVolt").value;
            ChartGauChargeAlternator.value = document.getElementById("hdnChrgAlter").value;
            ChartGauCoolantTemperature.value = document.getElementById("hdnCoolTemp").value;
            ChartGauOilTemperature.value = document.getElementById("hdnOilTemp").value;
            ChartGauOilPressure.value = document.getElementById("hdnOilPres").value;
            //ChartGauBatteryVoltage.value = document.getElementById("hEngine.value = document.getElementById("hdnBatteryVolt").value;   
            //ChartGauChargeAlternator.value    //ChartGauChargeAlte//ChartGauCoolantTemperature.value  //ChartGauCoolantTempe//ChartGauSpeedgauge.value          //ChartGauSpee//ChartGauOilTemperature.value      //ChartGauOilTemperature.value = "50";
            //document.getElementById('GauFreqgauge').value = document.getElementById("hdnFrequency").value;
            //$("#GauSpeedgauge").attr("data-value", (document.getElementById("hdnSpeed").value));
            //$("#GauBatteryCharger").attr("data-value", (document.getElementById("hdnBatteryCharger").value));

        }
    </script>--%>
</body>

</html>
