<%@ page language="VB" masterpagefile="~/MasterPage.master" autoeventwireup="false" inherits="PontoIndividual, App_Web_dledylua" title="Cronos - Módulo web" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <table border="0" cellpadding="0" cellspacing="0" style="width: 100%;">
        <tr>
            <td align="left" colspan="32" style="height: 20px; background-color: #5d7b9d; text-align: center">
                <asp:Label ID="TituloPontoIndividual" runat="server" Font-Bold="True" Font-Size="X-Small" ForeColor="Yellow" Text="Ponto"></asp:Label></td>
        </tr>
        <tr>
            <td style="height: 20px; background-color: #5d7b9d; text-align: Left" >
                <asp:Label ID="RotuloFiltro" runat="server" Text="Filtro:" ForeColor= "White" ></asp:Label>
                <asp:DropDownList ID="txtFiltro" runat="server" BackColor="#D6E0EE" Font-Size="X-Small"  AutoPostBack="True">
                <asp:ListItem></asp:ListItem></asp:DropDownList>&nbsp;
                <asp:Label ID="LabelValor1" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor1" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:DropDownList ID="cboCampo1" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"></asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo1" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo1" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo1" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData1" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:Label ID="LabelValor2" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor2" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                <asp:DropDownList ID="cboCampo2" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"> </asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo2" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo2" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo2" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData2" runat="server" Font-Size="X-Small"  Width="55px" Visible="False"></asp:TextBox>
                <asp:Label ID="LabelValor3" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor3" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                <asp:DropDownList ID="cboCampo3" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"></asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo3" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo3" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo3" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData3" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:ImageButton ID="Pesquisar3" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                <asp:Label ID="LabelValor4" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor4" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                <asp:DropDownList ID="cboCampo4" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"></asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo4" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo4" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo4" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData4" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:ImageButton ID="Pesquisar4" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                <asp:Label ID="LabelValor5" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor5" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                <asp:DropDownList ID="cboCampo5" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"></asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo5" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo5" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo5" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData5" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:ImageButton ID="Pesquisar5" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                <asp:Label ID="LabelValor6" runat="server" Text="Valor: " ForeColor="White"  Visible="False"></asp:Label>
                <asp:TextBox ID="txtFiltroValor6" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                <asp:DropDownList ID="cboCampo6" runat="server" AutoPostBack="True" Font-Size="X-Small" Visible="False"></asp:DropDownList>
                <asp:ImageButton ID="btnPesquisarCampo6" runat="server" ImageUrl="~/Imagens/LupaMais.png" ToolTip="Pesquisar" Visible="False" />
                <asp:ImageButton ID="btnOcultarPesquisarCampo6" runat="server" ImageUrl="~/Imagens/LupaMenos.png" ToolTip="Ocultar pesquisa" Visible="False" />&nbsp;
                <asp:ImageButton ID="btnEditPesquisaCampo6" runat="server" ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar Ordenação Pesquisa" Visible="False" />
                <asp:TextBox ID="txtFiltroData6" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                <asp:ImageButton ID="Pesquisar6" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
            </td>
            <td colspan="14" style="height: 20px; background-color: #5d7b9d; text-align: Right" >
                <asp:ImageButton ID="lnkInserir" runat="server" ImageUrl="~/Imagens/Add.png" ToolTip="Inserir novo registo" Width="30px" Visible="False" OnClientClick="target=''"/>
                <asp:ImageButton ID="btnPontoPessoal" runat="server" ImageUrl="~/Imagens/Relogio.png"  PostBackUrl="PontoPessoal.aspx" ToolTip="Ponto pessoal." Width="30px" OnClientClick="target=''"/>
                <asp:ImageButton ID="btnTabelasAuxiliares" runat="server" ImageUrl="~/Imagens/Tabelas.png" ToolTip="Configurar tabelas auxiliares" Width="30px" Visible="True" OnClientClick="target=''"/>
                <asp:ImageButton ID="lnkEMail" runat="server" ImageUrl="~/Imagens/Mail.png" ToolTip="Enviar Listagem por E-Mail" Width="30px" Visible="False" OnClientClick="target=''"/>
                <asp:ImageButton ID="btnImprimir" runat="server" ImageUrl="~/Imagens/print.gif" ToolTip="Imprimir" Width="30px" OnClientClick="target=''"/>
            </td>
        </tr>
        <tr>
            <td colspan="32" 
                style="height: 20px; background-color: White; text-align: center" 
                align="left"> 
                <asp:Label ID="lblMsg" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblFiltroContador" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblIndex" runat="server" Visible="False">NumeroEmpregado</asp:Label>&nbsp;
                <asp:Label ID="lblNumeroEmpregado" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblDataInicio" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblDataFim" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblFiltroAlterado" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
                <asp:Label ID="lblFiltroPonto" runat="server" Visible="False" BackColor="White"></asp:Label>
                <asp:Label ID="lblAccao" runat="server" Visible="False"></asp:Label>
                <asp:Label ID="lblCentrosCusto" runat="server" Visible="False"></asp:Label>&nbsp;
                <asp:Label ID="lblPessoalCentrosCusto" runat="server" Visible="False"></asp:Label>&nbsp;
                <asp:Label ID="lblEsta_Opcao" runat="server" Visible="False"></asp:Label> 
                <asp:Label ID="lblPeriodicidadeCompensacao" runat="server" Visible="False" BackColor="White"></asp:Label>&nbsp;
            </td>
        </tr>
        <tr>
            <td colspan="32" style="text-align: center">
            <asp:Panel ID="pnlEdit" runat="server" Visible="False" Width="100%">
                <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                        border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                        background-color: #d6e0ee">
                    <tr>
                        <td colspan="34" style="height: 20px; background-color: #d6e0ee; text-align: center">
                            <asp:Label ID="RotuloDataProc" runat="server" Text="Data proc.:"></asp:Label>
                            <asp:TextBox ID="txtDataProc" runat="server" BorderColor="Black" BorderWidth="1px" 
                                Enabled="False" Font-Size="X-Small" Width="60px" Wrap="False"></asp:TextBox>
                            <asp:Label ID="RotuloDataHora" runat="server" Text="Data Hora:"></asp:Label>
                            <asp:TextBox ID="txtData" runat="server" BorderColor="Black" BorderWidth="1px" 
                                Enabled="False" Font-Size="X-Small" Width="60px" Wrap="False" 
                                style="margin-left: 0px"></asp:TextBox>&nbsp;
                            <asp:TextBox ID="txtHora" runat="server" BorderColor="Black" BorderWidth="1px" 
                                Enabled="False" Font-Size="X-Small" Width="38px" Wrap="False"></asp:TextBox>&nbsp;&nbsp;&nbsp;&nbsp;
                            <asp:TextBox ID="txtHora2" runat="server" BorderColor="Black" BorderWidth="1px" 
                                Enabled="True" Font-Size="X-Small" Width="38px" Wrap="False" 
                                Visible="False"></asp:TextBox>&nbsp;
                            <asp:ImageButton ID="btnNovoRegisto" runat="server" 
                                ImageUrl="~/Imagens/Add2.png" ToolTip="Novo registo de ponto." />&nbsp;&nbsp;
                            <asp:ImageButton ID="btnEliminar" runat="server" 
                                ImageUrl="~/Imagens/Delete2.png" ToolTip="Eliminar" />&nbsp;&nbsp;&nbsp;&nbsp;
                            <asp:ImageButton ID="btnAnularEliminacao" runat="server" 
                                ImageUrl="~/Imagens/Anular.png" ToolTip="Anular eliminação de registos de ponto." />&nbsp;&nbsp;
                            <asp:LinkButton ID="lnkGravar" runat="server">Gravar</asp:LinkButton>&nbsp;&nbsp;
                            <asp:LinkButton ID="lnkCancelar" runat="server">Cancelar edição</asp:LinkButton>&nbsp;
                            <asp:Label ID="lblDataHoraOriginal" runat="server" Visible="False"></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="34" style="height: 20px; background-color: #d6e0ee; text-align: center">
                            <asp:Label ID="RotuloCartaoImportar" runat="server" Text="Exportar ponto do cartão nº"></asp:Label>&nbsp;
                            <asp:DropDownList ID="cboCartaoImportar" runat="server" 
                                AutoPostBack="True" Enabled="False" Font-Size="X-Small">
                            </asp:DropDownList>&nbsp;&nbsp;
                            <asp:Label ID="RotuloEmpregadoImportar" runat="server" Text="Para Empregado:"></asp:Label>&nbsp;
                            <asp:DropDownList ID="cboNumeroEmpregadoImportar" runat="server" AutoPostBack="True" 
                                Enabled="False" Font-Size="X-Small">
                            </asp:DropDownList>&nbsp;
                            <asp:ImageButton ID="btnIndex2" runat="server" 
                                ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar ordenação." Width="16px" />&nbsp;&nbsp;
                            <asp:DropDownList ID="cboNomeImportar" runat="server" AutoPostBack="True" 
                                Enabled="False" Font-Size="X-Small" Visible="False">
                            </asp:DropDownList>
                        </td>
                    </tr>
                </table>
            </asp:Panel>
            <asp:Panel ID="pnlEditNotas" runat="server" Width="100%" Visible="False">
                <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                    border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                    background-color: #d6e0ee">
                    <tr>
                        <td colspan="36" style="height: 20px; background-color: #d6e0ee; text-align: center">
                            <br />
                            <asp:Label ID="RotuloNotas" runat="server" Text="Notas:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtNotasFaltasExtras" runat="server" BorderColor="Black" BorderWidth="1px" 
                                Font-Size="X-Small" Width="500px" ></asp:TextBox>&nbsp;&nbsp;
                            <asp:ImageButton ID="btnEliminarPdf" runat="server" 
                                ImageUrl="~/Imagens/Delete2.png" ToolTip="Eliminar documento 'pdf'." Visible="True" />&nbsp;&nbsp;
                            <asp:LinkButton ID="lnkGravarNotas" runat="server">Gravar / Sair</asp:LinkButton>
                            <br />
                        </td>
                    </tr>
                    <tr>
                        <td colspan="36" style="height: 20px; background-color: #d6e0ee; text-align: center">
                            <br />
                            <asp:Label ID="RotuloFileUploadFaltasExtras" runat="server" Text="Anexar documento 'pdf':"></asp:Label>&nbsp;
                            <asp:FileUpload ID="FileUploadFaltasExtras" runat="server" ToolTip="Documento" 
                                BackColor="#F7F6F3" CssClass="icon" Font-Size="Small" Width="600px" 
                                Visible="False" />
                            <br /> <br />
                        </td>
                    </tr>
                </table>
            </asp:Panel>
            </td>
        </tr>

            <tr>
            <td colspan="34" style="text-align: center">
                <asp:Panel ID="pnlTabelasAuxiliares" runat="server" Visible="False" Width="100%">
                <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                        border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                        background-color: #d6e0ee">
                    <tr>
                        <td style="height: 10px; background-color: #d6e0ee; text-align: center">
                            <br />
                            <asp:Label ID="RotuloTabela" runat="server" Font-Size="X-Small" Text="Tabela:"></asp:Label>&nbsp;&nbsp;
                            <asp:DropDownList ID="cboTabela" runat="server" AutoPostBack="True" 
                                Font-Size="X-Small" Width="200px" > </asp:DropDownList>
                        </td>
                    </tr> 
                    <tr>
                        <td style="height: 30px; background-color: #d6e0ee; text-align: center">
                            <br /> 
                            <asp:Label ID="RotuloCodigo" runat="server" Text="Código:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtCodigoTabelaAuxiliar" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="47px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloTipoSubsidio" runat="server" Text="Código:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtTipoSubsidio" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloNumero" runat="server" Text="Número:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtNumero" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloDescricao" runat="server" Text="Descrição:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtDescricaoTabelaAuxiliar" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="235px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloAbreviatura" runat="server" Text="Abreviatura:"></asp:Label>&nbsp;
                            <asp:TextBox ID="TxtAbreviatura" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="47px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloCodigoExterno" runat="server" Text="Código Externo:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtCodigoExterno" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="47px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloMinimoHoras" runat="server" Text="Mín Horas Trab. Dia:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtMinimoHoras" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloDias" runat="server" Text="Dias Úteis:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtDias" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloLimiteHorasFalta" runat="server" Text="Lim. H. Faltas/Mês:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtLimiteHorasFalta" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloLimiteDiasFalta" runat="server" Text="Lim. D. Faltas/Mês:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtLimiteDiasFalta" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;
                            <asp:Label ID="RotuloLimiteDiasTrabalho" runat="server" Text="Dias Trab. Consecutivos:"></asp:Label>&nbsp;
                            <asp:TextBox ID="txtLimiteDiasTrabalho" runat="server" BorderWidth="1px" Font-Size="X-Small" Width="30px"></asp:TextBox>&nbsp;&nbsp;
                            <asp:LinkButton ID="lnkTabelaAuxiliarGravar" runat="server">Gravar</asp:LinkButton>&nbsp;&nbsp;
                            <asp:ImageButton ID="btnTabelaAuxiliarNovoFiltro" runat="server" 
                                ImageUrl="~/Imagens/Add2.png" ToolTip="Novo filtro." />&nbsp;&nbsp;
                            <asp:ImageButton ID="btnTabelaAuxiliarAlterarFiltro" runat="server" 
                                ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar filtro." Width="16px" />&nbsp;&nbsp;
                            <asp:LinkButton ID="lnkTabelaAuxiliarSair" runat="server">Sair</asp:LinkButton>
                            <br />  <br />
                            <asp:GridView ID="grdDadosTabelasAuxiliares" runat="server" CellPadding="4" HorizontalAlign="Center" 
                                    PageSize="4" Width="702px" RowStyle-HorizontalAlign="Left">
                                <Columns>
                                    <asp:CommandField SelectText="" ShowSelectButton="True" ButtonType="Image" 
                                        SelectImageUrl="~/Imagens/Edit2.png" 
                                        DeleteImageUrl="~/Imagens/Delete2.png" ShowDeleteButton="True" />
                                </Columns>
                                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                                <EditRowStyle BackColor="#999999" />
                                <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="~/Imagens/SetaPrimeiro.png" PreviousPageImageUrl="~/Imagens/SetaEsquerda.png" NextPageImageUrl="~/Imagens/SetaDireita.png" LastPageImageUrl="~/Imagens/SetaUltimo.png" />
                                <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                                <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                                <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                                <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                            </asp:GridView>

                        </td>
                    </tr>

                    <tr>
                    <td style="height: 20px; background-color: #d6e0ee; text-align: center">
                        <asp:GridView ID="grdDadosOpcoesFiltros" runat="server"  
                                AutoGenerateColumns="False" CellPadding="4" HorizontalAlign="Center" 
                                    PageSize="4" Width="600px">
                        <Columns>
                            <asp:CommandField SelectText="" ShowSelectButton="True" ButtonType="Image" SelectImageUrl="~/Imagens/Edit2.png" 
                                        DeleteImageUrl="~/Imagens/Delete2.png" ShowDeleteButton="True" />
                            <asp:BoundField DataField="Descricao" HeaderText="Filtro" />
                            <asp:TemplateField HeaderText="Activo">
                                <ItemTemplate>
                                    <asp:CheckBox ID="chkFiltroActivo" runat="server" AutoPostBack="True" OnCheckedChanged="chkFiltroActivo_Clicked" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Filtro" HeaderText="" />
                            <asp:BoundField DataField="Activo" HeaderText="" />
                        </Columns>
                        <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                        <EditRowStyle BackColor="#999999" />
                        <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="~/Imagens/SetaPrimeiro.png" PreviousPageImageUrl="~/Imagens/SetaEsquerda.png" NextPageImageUrl="~/Imagens/SetaDireita.png" LastPageImageUrl="~/Imagens/SetaUltimo.png" />
                        <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                        <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                        <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        </asp:GridView>

                        <br />  
                        <asp:Label ID="RotuloContador" runat="server" Text="Ordem:" Visible="False"></asp:Label>&nbsp;
                        <asp:TextBox ID="txtContador" runat="server" BorderWidth="1px" Font-Size="X-Small" 
                                    Width="25px" Visible="False"></asp:TextBox>&nbsp;
                        <asp:TextBox ID="txtParenteses1" runat="server" BorderWidth="1px" Font-Size="X-Small" 
                                    Width="10px" Visible="False"></asp:TextBox>&nbsp;
                        <asp:Label ID="RotulocboCampos" runat="server" Text="Campo:" Visible="False"></asp:Label>&nbsp;
                        <asp:DropDownList ID="cboCampos" runat="server" Font-Size="X-Small" 
                                    Visible="False"> </asp:DropDownList>&nbsp;
                        <asp:Label ID="RotuloOperador" runat="server" Text="Operador:" Visible="False"></asp:Label>&nbsp;
                        <asp:DropDownList ID="cboOperadores" runat="server" Font-Size="X-Small" 
                                    Visible="False"> </asp:DropDownList>&nbsp;
                        <asp:Label ID="RotuloValor" runat="server" Text="Valor:" Visible="False"></asp:Label>&nbsp;
                        <asp:TextBox ID="txtValor" runat="server" BorderWidth="1px" Font-Size="X-Small" 
                                    Width="80px" Visible="False"></asp:TextBox>&nbsp;
                        <asp:TextBox ID="txtParenteses2" runat="server" BorderWidth="1px" Font-Size="X-Small" 
                                    Width="10px" Visible="False"></asp:TextBox>&nbsp;
                        <asp:Label ID="RotuloCondicao" runat="server" Text="Condição:" Visible="False"></asp:Label>&nbsp;
                        <asp:DropDownList ID="cboCondicao" runat="server" Font-Size="X-Small" 
                                    Visible="False"> </asp:DropDownList>&nbsp;&nbsp;
                        <asp:ImageButton ID="btnNovoCampo" runat="server" 
                            ImageUrl="~/Imagens/Add2.png" ToolTip="Inserir Novo registo." Visible="False" />&nbsp;
                        <asp:ImageButton ID="btnAlterarCampo" runat="server" 
                            ImageUrl="~/Imagens/Edit2.png" ToolTip="Alterar filtro." Width="16px" Visible="False" />
                        <br /> <br />

                        <asp:GridView ID="grdDadosOpcoesFiltrosCampos" runat="server"  
                                AutoGenerateColumns="False" CellPadding="4" HorizontalAlign="Center" 
                                    PageSize="4" Width="800px" Visible="False">
                        <Columns>
                            <asp:CommandField SelectText="" ShowSelectButton="True" ButtonType="Image" SelectImageUrl="~/Imagens/Edit2.png" 
                                        DeleteImageUrl="~/Imagens/Delete2.png" ShowDeleteButton="True" />
                            <asp:BoundField DataField="Descricao" HeaderText="Filtro" />
                            <asp:BoundField DataField="Contador" HeaderText="Ordem"/>
                            <asp:BoundField DataField="Parenteses1" HeaderText=" " />
                            <asp:TemplateField HeaderText="Campo">
                            <ItemTemplate>
                                <asp:DropDownList ID="dropOpcoesCampos" runat="server" AutoPostBack="True" 
                                    Font-Size="X-Small" CssClass="drop" Height="15px" onload="dropOpcoesCampos_Load" 
                                    onselectedindexchanged="dropOpcoesCampos_SelectedIndexChanged" >
                                </asp:DropDownList>
                                </span>
                            </ItemTemplate>                            
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="Operador">
                                <ItemTemplate>
                                <asp:DropDownList ID="DropOperacao" runat="server" AutoPostBack="True" 
                                    Font-Size="X-Small" CssClass="drop" Height="15px" onload="DropOperacao_Load" 
                                    onselectedindexchanged="DropOperacao_SelectedIndexChanged">
                                </asp:DropDownList>
                                </span>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Valor" HeaderText="Valor" />
                            <asp:BoundField DataField="Parenteses2" HeaderText=" " />
                            <asp:TemplateField HeaderText="Condição">
                                <ItemTemplate>
                                <asp:DropDownList ID="DropConjuncao" runat="server" AutoPostBack="True" 
                                    Font-Size="X-Small" CssClass="drop" Height="15px" onload="DropConjuncao_Load" 
                                    onselectedindexchanged="DropConjuncao_SelectedIndexChanged">
                                </asp:DropDownList>
                                </span>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="Tipo" HeaderText="" />
                            <asp:BoundField DataField="Filtro2" HeaderText="" />
                            <asp:BoundField DataField="Opcao2" HeaderText=""/>
                            <asp:BoundField DataField="Campo2" HeaderText=""/>
                            <asp:BoundField DataField="Contador2" HeaderText=""/>
                            <asp:BoundField DataField="NumeroEmpregado2" HeaderText=""/>
                            <asp:BoundField DataField="Condicao" HeaderText=""/>
                            <asp:BoundField DataField="Conjuncao" HeaderText=""/>
                        </Columns>
                        <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                        <EditRowStyle BackColor="#999999" />
                        <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="~/Imagens/SetaPrimeiro.png" PreviousPageImageUrl="~/Imagens/SetaEsquerda.png" NextPageImageUrl="~/Imagens/SetaDireita.png" LastPageImageUrl="~/Imagens/SetaUltimo.png" />
                        <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                        <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                        <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        </asp:GridView>
                        <br />
                    </td>
                    </tr>

                </table>
                </asp:Panel>
            </td>
            </tr>


        <tr>
        <td colspan="36" style="text-align: center">
            <asp:Panel ID="pnlOpcoesCampos" runat="server" Visible="False" Width="100%">
            <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                    border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                    background-color: #d6e0ee">
                <%--<tr align="center">
                    <td style="height: 3px; text-align: center">
                        <asp:LinkButton ID="lnkSair3" runat="server">Sair</asp:LinkButton>
                    </td>
                </tr>--%>
                <tr>
                    <td 
                        style="height: 20px; background-color: White; text-align: center" 
                        align="left"> 
                        <asp:Label ID="lblMsg3" runat="server" Visible="False" BackColor="White"></asp:Label> 
                    </td>
                </tr>
                <tr>
                    <td style="height: 20px; background-color: #d6e0ee; text-align: center">
                        <asp:Label ID="RotuloTituloOpcoesCampos" runat="server" Font-Size="X-Small" Text="Visualizar / ocultar campos"></asp:Label>&nbsp;&nbsp;
                        </td>
                </tr> 
                <tr>
                    <td style="height: 30px; background-color: #d6e0ee; text-align: center">
                        <br /> 
                        <asp:Label ID="Label8" runat="server" Text="Campo / coluna:"></asp:Label>&nbsp;
                        <asp:TextBox ID="TxtCampoColunaOpcoesCampos" runat="server" BorderColor="Black" BorderWidth="1px" 
                            Font-Size="X-Small" Width="235px"></asp:TextBox>&nbsp;
                        <asp:LinkButton ID="lnkOpcoesCamposGravar" runat="server">Gravar</asp:LinkButton>
                        &nbsp;&nbsp;
                        <asp:LinkButton ID="lnkOpcoesCamposSair" runat="server">Sair</asp:LinkButton>
                        <br />  <br />
                        <asp:GridView ID="grdDadosOpcoesCampos" runat="server" CellPadding="4" HorizontalAlign="Center" 
                                PageSize="4" Width="582px" AutoGenerateColumns="False">
                            <Columns>
                                <asp:CommandField SelectText="" ShowSelectButton="True" ButtonType="Image" 
                                    SelectImageUrl="~/Imagens/Edit2.png" />
                                <asp:BoundField DataField="Descricao" HeaderText="Campo / coluna" />
                                <asp:TemplateField HeaderText="Visualizar">
                                    <ItemTemplate>
                                        <asp:CheckBox ID="chkVisualizarOpcoesCampos" runat="server" AutoPostBack="True" OnCheckedChanged="chkVisualizarOpcoesCampos_Clicked" />
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:BoundField DataField="Campo" HeaderText="" />
                                <asp:BoundField DataField="Visualizar" HeaderText="" />
                            </Columns>
                            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                            <EditRowStyle BackColor="#999999" />
                            <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="Imagens/SetaPrimeiro.png" PreviousPageImageUrl="Imagens/SetaEsquerda.png" NextPageImageUrl="Imagens/SetaDireita.png" LastPageImageUrl="Imagens/SetaUltimo.png" />
                            <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        </asp:GridView>
                    </td>
                </tr>
            </table>
        </asp:Panel>
        </td>
        </tr>


        <tr>
        <td colspan="32">
            <%--<asp:TextBox ID="notes" runat="server" Height="20px" MaxLength="200" TextMode="MultiLine" Width="100%"></asp:TextBox>--%>
            <asp:GridView ID="grdDadosPonto" runat="server" CellPadding="4" ForeColor="#333333" 
                        GridLines="Vertical" Width="100%" AllowPaging="True" PageSize="16" 
                        style="margin-top: 0px" >
                <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                <Columns>
                    <asp:CommandField SelectText="&gt;" ShowSelectButton="True" ButtonType="Image" SelectImageUrl="~/Imagens/Selecao.png" />
                </Columns>
                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                <EditRowStyle BackColor="#999999" />
                <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="Imagens/SetaPrimeiro.png" PreviousPageImageUrl="Imagens/SetaEsquerda.png" NextPageImageUrl="Imagens/SetaDireita.png" LastPageImageUrl="Imagens/SetaUltimo.png" />
                <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
            </asp:GridView>
        </td>
        </tr>

        <tr align="center">
        <td colspan="36" style="text-align: center" align="center">
        <asp:Panel ID="pnlFaltasExtras" runat="server" Visible="False" Width="100%">
        <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                background-color: #d6e0ee" >
            <tr>
            <td style="height: 20px; background-color: #5d7b9d; text-align: center ">
                <asp:Label ID="RotuloFaltasExtras" runat="server" ForeColor="Yellow" Text="Ausências / extras"></asp:Label>
                </td>
            </tr> 
            <tr align="center">
            <td style="height: 20px; background-color: #d6e0ee; text-align: center">
                <asp:GridView ID="grdDadosFaltasExtras" runat="server" CellPadding="4" 
                    ForeColor="#333333" GridLines="Vertical" Width="100%" AllowPaging="True" 
                    AutoGenerateColumns="False" HorizontalAlign="Center" >
                <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                <Columns>
                    <asp:CommandField ButtonType="Image" DeleteImageUrl="~/Imagens/Delete2.png" ShowDeleteButton="True" />
                    <asp:BoundField DataField="NumeroEmpregado" HeaderText="Núm." />
                    <asp:BoundField DataField="Nome" HeaderText="Nome" />
                    <asp:BoundField HeaderText="Dia" DataField="Data" />
                    <asp:BoundField DataField="Data" HeaderText="Data" ReadOnly="True" />
                    <asp:BoundField DataField="IniFalta" HeaderText="Início" />
                    <asp:BoundField DataField="FimFalta" HeaderText="Fim" />
                    <asp:BoundField DataField="HorasFalta" HeaderText="Horas" />
                    <asp:TemplateField HeaderText="Cód. falta">
                    <ItemTemplate>
                        <asp:DropDownList ID="dropFaltas" runat="server" AutoPostBack="True" 
                            Font-Size="X-Small" CssClass="drop" Height="15px" onload="dropFaltas_Load" 
                            onselectedindexchanged="dropFaltas_SelectedIndexChanged" >
                        </asp:DropDownList>
                        </span>
                    </ItemTemplate>                            
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="Confirmação">
                        <ItemTemplate>
                        <asp:DropDownList ID="DropConfirmacao" runat="server" AutoPostBack="True" 
                            Font-Size="X-Small" CssClass="drop" Height="15px" onload="DropConfirmacao_Load" 
                            onselectedindexchanged="DropConfirmacao_SelectedIndexChanged">
                        </asp:DropDownList>
                        </span>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="IniExtra" HeaderText="Início" />
                    <asp:BoundField DataField="FimExtra" HeaderText="Fim" />
                    <asp:BoundField DataField="HorasExtra" HeaderText="Horas" />
                    <asp:TemplateField HeaderText="Cód. extra">
                    <ItemTemplate>
                        <asp:DropDownList ID="dropExtras" runat="server" AutoPostBack="True" 
                            Font-Size="X-Small" CssClass="drop" Height="15px" onload="dropExtras_Load" 
                            onselectedindexchanged="dropExtras_SelectedIndexChanged">
                        </asp:DropDownList>
                        </span>
                    </ItemTemplate>                            
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="Justificação">
                    <ItemTemplate>
                        <asp:DropDownList ID="dropJustificacao" runat="server" AutoPostBack="True" 
                            Font-Size="X-Small" CssClass="drop" Height="15px" onload="dropJustificacao_Load" 
                            onselectedindexchanged="dropJustificacao_SelectedIndexChanged">
                        </asp:DropDownList>
                        </span>
                    </ItemTemplate>                            
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="Validado">
                        <ItemTemplate>
                            <asp:CheckBox ID="chkValidadoFaltasExtras" runat="server" AutoPostBack="True" OnCheckedChanged="chkValidadoFaltasExtras_Clicked" />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <%--<asp:BoundField DataField="Notas" HeaderText="Notas"/>--%>
                        <asp:TemplateField HeaderText="Notas">
                            <ItemTemplate>
                                <table cellpadding="0" cellspacing="0" class="style3">
                                    <tr>
                                    <td>
                                        <asp:Label ID="lblNotas" runat="server" />
                                        <asp:imagebutton ID="btnNotas" runat="server"  
                                            Height="12px" OnClick="btnNotas_Click" ImageUrl="~/Imagens/Edit2.png" ToolTip="Editar notas." Width="12px" />
                                    </td>
                                    </tr>
                                </table>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="doc.">
                            <ItemTemplate>
                                <table cellpadding="0" cellspacing="0" class="style3">
                                    <tr>
                                    <td>
                                        <asp:imagebutton ID="btnPdf" runat="server"  
                                            Height="12px" OnClick="btnVerPdf_Click" ImageUrl="~/Imagens/pdf.png" ToolTip="Baixar documento 'Pdf'." Width="12px" />
                                    </td>
                                    </tr>
                                </table>
                            </ItemTemplate>
                        </asp:TemplateField>
                    <asp:BoundField DataField="CodigoFalta" HeaderText=""/>
                    <asp:BoundField DataField="ConfirmacaoFalta" HeaderText=""/>
                    <asp:BoundField DataField="CodigoExtra" HeaderText=""/>
                    <asp:BoundField DataField="JustificacaoExtra" HeaderText=""/>
                    <asp:BoundField DataField="TipoHora" />
                    <asp:BoundField DataField="DataInicio" />
                    <asp:BoundField DataField="Validado" HeaderText="" />
                    <asp:BoundField DataField="IdObjecto" HeaderText="" />
                </Columns>
                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                <EditRowStyle BackColor="#999999" />
                <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="Imagens/SetaPrimeiro.png" PreviousPageImageUrl="Imagens/SetaEsquerda.png" NextPageImageUrl="Imagens/SetaDireita.png" LastPageImageUrl="Imagens/SetaUltimo.png" />
                <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                </asp:GridView>
            </td>
            </tr>
                <tr>
                    <%--<td colspan="36" style="height: 12px" align="right" bgcolor="#5d7b9d">--%>
                    <td colspan="36" style="height: 12px" align="right" >
                    <asp:Panel ID="Panel1" runat="server" BackColor="#5d7b9d">
                        <asp:ImageButton ID="btnOpcoesCamposFaltasExtras" runat="server"  ImageUrl="~/Imagens/Config.png" ToolTip="Configurar ocultação campos/colunas"/>&nbsp;
                    </asp:Panel>
                    </td>                 
                </tr>
        </table>
        </asp:Panel>
        </td>
        </tr>


        <tr>
        <td colspan="36" style="text-align: center">
        <asp:Panel ID="pnlHorarios" runat="server" Visible="False" Width="100%">
        <table border="0" cellpadding="0" cellspacing="0" style="border-right: black 1px solid;
                border-top: black 1px solid; border-left: black 1px solid; width: 100%; border-bottom: black 1px solid;
                background-color: #d6e0ee">
            <tr>
                <td align="left" colspan="32" style="height: 10px; background-color: #5d7b9d; text-align: center">
                    <asp:Label ID="TituloHorarios" runat="server" Font-Bold="True" Font-Size="X-Small" ForeColor="Yellow" Text="Horários"></asp:Label></td>
            </tr>
            <tr> <td style="height: 5px; background-color: White;"> </td> </tr>
            <tr>
                <td colspan="32" style="height: 20px; background-color: #5d7b9d; text-align: left" >
                    <asp:Label ID="Label2" runat="server" Text="Filtro Horário:" ForeColor= "White" ></asp:Label>
                    <asp:DropDownList ID="txtFiltroHorarios" runat="server" BackColor="#D6E0EE" Font-Size="X-Small"  AutoPostBack="True">
                    <asp:ListItem></asp:ListItem></asp:DropDownList>&nbsp;
                    <asp:Label ID="LabelHorariosValor1" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor1" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData1" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:Label ID="LabelHorariosValor2" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor2" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData2" runat="server" Font-Size="X-Small"  Width="55px" Visible="False"></asp:TextBox>
                    <asp:Label ID="LabelHorariosValor3" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor3" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData3" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:ImageButton ID="PesquisarHorarios3" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                    <asp:Label ID="LabelHorariosValor4" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor4" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData4" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:ImageButton ID="PesquisarHorarios4" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                    <asp:Label ID="LabelHorariosValor5" runat="server" Text="Valor: " ForeColor="White" Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor5" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData5" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:ImageButton ID="PesquisarHorarios5" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                    <asp:Label ID="LabelHorariosValor6" runat="server" Text="Valor: " ForeColor="White"  Visible="False"></asp:Label>
                    <asp:TextBox ID="txtFiltroHorariosValor6" runat="server" Font-Size="X-Small" Width="55px" Visible="False"></asp:TextBox>
                    <asp:TextBox ID="txtFiltroHorariosData6" runat="server" Font-Size="X-Small" Visible="False" Width="55px"></asp:TextBox>
                    <asp:ImageButton ID="PesquisarHorarios6" runat="server" ImageUrl="~/Imagens/Lupa2.png" ToolTip="Executar filtro" OnClientClick="target=''" Width="24px" Visible="False"/>
                </td>
            </tr>
            <tr> <td style="height: 5px; background-color: White;"> </td> </tr>
            <tr>
            <td colspan="32">
                <asp:GridView ID="grdDadosHorarios" runat="server" CellPadding="4" 
                    ForeColor="#333333" GridLines="Vertical" Width="100%" AllowPaging="True" 
                    PageSize="16" AutoGenerateColumns="False">
                    <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <Columns>
                        <asp:CommandField SelectText="&gt;" ShowSelectButton="True" ButtonType="Image" SelectImageUrl="~/Imagens/Selecao.png" />
                        <asp:BoundField DataField="DescHorario" HeaderText="Horário" ReadOnly="True" />
                        <asp:TemplateField HeaderText="Dia da Semana">
                        <ItemTemplate>
                            <asp:DropDownList ID="dropDiadeSemana" runat="server" AutoPostBack="True" 
                                Font-Size="X-Small" CssClass="drop" Height="19px" onload="dropDiadeSemana_Load" 
                                onselectedindexchanged="dropDiadeSemana_SelectedIndexChanged" >
                            </asp:DropDownList>
                            </span>
                        </ItemTemplate>                            
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Tipo Período">
                        <ItemTemplate>
                            <asp:DropDownList ID="dropTipoPeriodo" runat="server" AutoPostBack="True" 
                                Font-Size="X-Small" CssClass="drop" Height="19px" onload="dropTipoPeriodo_Load" 
                                onselectedindexchanged="dropTipoPeriodo_SelectedIndexChanged" >
                            </asp:DropDownList>
                            </span>
                        </ItemTemplate>                            
                        </asp:TemplateField>
                        <asp:BoundField DataField="HoraInicio" HeaderText="Início" DataFormatString="{0:t}" 
                            ApplyFormatInEditMode="True" ReadOnly="True"/>
                        <asp:TemplateField HeaderText="Processamento">
                            <ItemTemplate>
                                <asp:DropDownList ID="DropDiaProcessamentoIni" runat="server" AutoPostBack="True" 
                                    onselectedindexchanged="DropDiaProcessamentoIni_SelectedIndexChanged" 
                                    SelectedValue='<%# Bind("DiaInicio") %>' Font-Size="X-Small" Height="19px">
                                    <asp:ListItem></asp:ListItem>
                                    <asp:ListItem Value="-1">Dia Anterior</asp:ListItem>
                                    <asp:ListItem Value="0">Próprio Dia</asp:ListItem>
                                    <asp:ListItem Value="1">Dia Seguinte</asp:ListItem>
                                </asp:DropDownList>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:BoundField DataField="ToleranciaInicio" HeaderText="Tolerância"/>
                        <asp:BoundField DataField="HoraFim" HeaderText="Fim" DataFormatString="{0:t}" 
                            ApplyFormatInEditMode="True" ReadOnly="True"/>
                        <asp:TemplateField HeaderText="Processamento">
                            <ItemTemplate>
                                <asp:DropDownList ID="DropDiaProcessamentoFim" runat="server" AutoPostBack="True" 
                                    onselectedindexchanged="DropDiaProcessamentoFim_SelectedIndexChanged" 
                                    SelectedValue='<%# Bind("DiaFim") %>' Font-Size="X-Small" Height="19px">
                                    <asp:ListItem></asp:ListItem>
                                    <asp:ListItem Value="-1">Dia Anterior</asp:ListItem>
                                    <asp:ListItem Value="0">Próprio Dia</asp:ListItem>
                                    <asp:ListItem Value="1">Dia Seguinte</asp:ListItem>
                                </asp:DropDownList>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:BoundField DataField="ToleranciaFim" HeaderText="Tolerância"/>
                        <asp:BoundField DataField="MinimoHoras" HeaderText="Mín Horas"/>
                        <asp:BoundField DataField="MaximoHoras" HeaderText="Máx. Horas"/>
                        <asp:BoundField DataField="DiadeSemana" HeaderText=""/>
                        <asp:BoundField DataField="TipoPeriodo" HeaderText=""/>
                        <asp:BoundField DataField="Horario" HeaderText=""/>
                    </Columns>
                    <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                    <EditRowStyle BackColor="#999999" />
                    <PagerSettings Visible="true"  Position="Bottom" Mode="NextPreviousFirstLast" FirstPageImageUrl="Imagens/SetaPrimeiro.png" PreviousPageImageUrl="Imagens/SetaEsquerda.png" NextPageImageUrl="Imagens/SetaDireita.png" LastPageImageUrl="Imagens/SetaUltimo.png" />
                    <PagerStyle BackColor="#F7F6F3" ForeColor="#5D7B9D" Font-Size="Small" HorizontalAlign="Center" />
                    <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                    <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                </asp:GridView>
            </td>
            </tr>
        </table>
        </asp:Panel>
        </td>
        </tr>

        <tr>
            <td colspan="32" style="height: 12px" align="right" >
            <br />
            <asp:Panel ID="pnlOpcoesRodape" runat="server" Visible="True" Width="100%" BackColor="#5d7b9d">
                <asp:CheckBox ID="ChkVisualizarTotais" runat="server" ForeColor="White" 
                    Text="Totais" TextAlign="Left" Visible="True" AutoPostBack="True" />&nbsp;
                <asp:CheckBox ID="ChkVisualizarExtraFaltas" runat="server" ForeColor="White" 
                    Text="Extra / Faltas" TextAlign="Left" Visible="True" 
                    AutoPostBack="True"/>&nbsp;
                <asp:CheckBox ID="ChkFiltroporOmissao" runat="server" ForeColor="White" 
                    Text="Filtro p/ omissão" TextAlign="Left" Visible="False" 
                    AutoPostBack="True" />&nbsp;
                <asp:Label ID="RotuloGrelha" runat="server" Text="Grelha: " 
                    ForeColor="White"></asp:Label>&nbsp;
                <asp:DropDownList ID="cboGrelha" runat="server" Font-Size="X-Small" 
                    BackColor="White" ForeColor="Black">
                    <asp:ListItem Value="0">Vertical</asp:ListItem>
                    <asp:ListItem Value="1">Horizontal</asp:ListItem>
                    <asp:ListItem Value="2">Ambos</asp:ListItem>
                </asp:DropDownList>&nbsp;
                <asp:Label ID="RotuloLinhasPagina" runat="server" Text="Paginação Linhas:" 
                    ForeColor="White"></asp:Label>&nbsp;
                <asp:TextBox ID="txtLinhasPagina" runat="server" BorderColor="White" 
                    BorderWidth="0px" Font-Size="X-Small" Height="18px" Width="30px" 
                    BackColor="#5D7B9D" ForeColor="White" ></asp:TextBox>
                <asp:Label ID="Label3" runat="server" Text="Posição: " 
                    ForeColor="White"></asp:Label>&nbsp;
                <asp:DropDownList ID="cboPaginacaoPosicao" runat="server" Font-Size="X-Small" 
                    BackColor="White" ForeColor="Black">
                    <asp:ListItem Value="0">Em baixo</asp:ListItem>
                    <asp:ListItem Value="1">Em cima</asp:ListItem>
                    <asp:ListItem Value="2">Em ambos</asp:ListItem>
                </asp:DropDownList>&nbsp;
                <asp:Label ID="Label4" runat="server" Text="Tipo: " 
                    ForeColor="White"></asp:Label>&nbsp;
                <asp:DropDownList ID="cboPaginacaoTipo" runat="server" Font-Size="X-Small" 
                    BackColor="White" ForeColor="Black">
                    <asp:ListItem Value="2">Botões</asp:ListItem>
                    <asp:ListItem Value="3">Nº pág.</asp:ListItem>
                </asp:DropDownList>&nbsp;
                <asp:ImageButton ID="btnGravarOpoes" runat="server"  ImageUrl="~/Imagens/Edit2.png" ToolTip="Gravar opções"/>&nbsp;
            </asp:Panel>
            </td>                 
        </tr>
    </table>
</asp:Content>

