Usuário com melhor resposta
O nome RadGrid1 não existe no contexto atual

Pergunta
-
Bom dia, estou tentando pegar a minha RadGrid1 no backend porem da esse erro ai mencionado no titulo, nao sei mais o que fazer alguem pode me ajudar?
Código aspx:
<telerik:RadGrid ID="RadGrid" runat="server"
AllowPaging="true"
AllowFilteringByColumn="true"
Skin="Vista"
AllowSorting="true"
AutoGenerateColumns="False"
OnNeedDataSource="RadGrid_NeedDataSource"
OnItemCommand="RadGrid_ItemCommand"
OnItemCreated="RadGrid_ItemCreated"
FilterMenu-CollapseDelay="10000" SortingSettings-SortedAscToolTip="Crescente" SortingSettings-SortedDescToolTip="Decrescente">
<GroupingSettings CaseSensitive="false" />
<SortingSettings SortToolTip="Clique aqui para ordenar" />
<HierarchySettings CollapseTooltip="Clique aqui para recolher" ExpandTooltip="Clique aqui para expandir" SelfCollapseTooltip="" SelfExpandTooltip="" />
<PagerStyle FirstPageToolTip="Primeira Página" LastPageToolTip="Ultima Página" NextPagesToolTip="Proximas páginas" NextPageToolTip="Proxima página" PagerTextFormat="Alterar página: {4} &nbsp;Página <strong>{0}</strong> de <strong>{1}</strong>" PageSizeLabelText="Quantidade de Registros:" PrevPagesToolTip="Páginas anteriores" PrevPageToolTip="Página anterior" />
<MasterTableView DataKeyNames="ANO_MES,FPFUNCIONARIO_ID,IRRF,PREV" AllowMultiColumnSorting="false" ShowHeader="true" NoDetailRecordsText="Sem registros para exibir." NoMasterRecordsText="Sem registros para exibir."
ExpandCollapseColumn-ButtonType="ImageButton"
ExpandCollapseColumn-CollapseImageUrl="Library/Imagem/collapse.gif"
ExpandCollapseColumn-ExpandImageUrl="Library/Imagem/expandRed.gif"
ExpandCollapseColumn-HeaderText="Expandir">
<Columns>
<telerik:GridBoundColumn DataField="FPFUNCIONARIO_ID" AutoPostBackOnFilter="false"
HeaderText="Matrícula"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="ANO_MES"
HeaderText="Ano/Mes"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="NOME" HeaderText="Nome" CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="CARGO" HeaderText="Cargo" AutoPostBackOnFilter="false"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="CARGO_ATUAL" HeaderText="Cargo Atual" AutoPostBackOnFilter="false"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="T_FUNCIONARIO" HeaderText="Tipo de Funcionário" AutoPostBackOnFilter="false"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="DIVISAO" HeaderText="Divisão" AutoPostBackOnFilter="false"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="SECAO" HeaderText="Seção" AutoPostBackOnFilter="false"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="DTA_ADMISSAO" HeaderText="Admissão" DataFormatString="{0:dd/MM/yyyy}"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="DTA_DEMISSAO" HeaderText="Demissão" DataFormatString="{0:dd/MM/yyyy}"
CurrentFilterFunction="Contains"
ShowFilterIcon="false"
FilterDelay="2000"
FilterControlWidth="100%">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="VALOR_GANHO" HeaderText="Total de Ganhos" DataFormatString="R$ {0:N}" AllowFiltering="false">
<FooterStyle Width="110px"></FooterStyle>
<HeaderStyle Width="110px"></HeaderStyle>
<ItemStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="OUTROS_DESCONTOS" HeaderText="Outros Descontos" DataType="System.Decimal" DataFormatString="R$ {0:N}" AllowFiltering="false">
<FooterStyle Width="110px"></FooterStyle>
<HeaderStyle Width="110px"></HeaderStyle>
<ItemStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="IRRF" HeaderText="Imposto de Renda" DataFormatString="R$ {0:N}" AllowFiltering="false">
<FooterStyle Width="120px"></FooterStyle>
<HeaderStyle Width="120px"></HeaderStyle>
<ItemStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="PREV" HeaderText="Previdência" DataFormatString="R$ {0:N}" AllowFiltering="false">
<FooterStyle Width="80px"></FooterStyle>
<HeaderStyle Width="80px"></HeaderStyle>
<ItemStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
</Columns>
<NestedViewTemplate>
<asp:Panel runat="server" ID="InnerContainer1" CssClass="viewWrap" Visible="false">
<%--INÍCIO DA GRID RadGrid1--%>
<telerik:RadGrid ID="RadGrid1" runat="server"
AllowPaging="True"
AllowFilteringByColumn="true"
Skin="Vista"
AllowSorting="true"
AutoGenerateColumns="False"
OnNeedDataSource="RadGrid1_NeedDataSource"
OnItemCommand="RadGrid1_ItemCommand"
OnItemCreated="RadGrid_ItemCreated"
FilterMenu-CollapseDelay="10000" SortingSettings-SortedAscToolTip="Crescente" SortingSettings-SortedDescToolTip="Decrescente">
<GroupingSettings CaseSensitive="false" />
<SortingSettings SortToolTip="Clique aqui para ordenar" />
<HierarchySettings CollapseTooltip="Clique aqui para recolher" ExpandTooltip="Clique aqui para expandir" SelfCollapseTooltip="" SelfExpandTooltip="" />
<ClientSettings EnableRowHoverStyle="true">
<Selecting AllowRowSelect="false" />
<ClientMessages PagerTooltipFormatString="Página <strong>{0}</strong> de <strong>{1}</strong>" />
</ClientSettings>
<GroupPanel Text="">
</GroupPanel>
<PagerStyle FirstPageToolTip="Primeira Página" LastPageToolTip="Ultima Página" NextPagesToolTip="Proximas páginas" NextPageToolTip="Proxima página" PagerTextFormat="Alterar página: {4} &nbsp;Página <strong>{0}</strong> de <strong>{1}</strong>" PageSizeLabelText="Quantidade de Registros:" PrevPagesToolTip="Páginas anteriores" PrevPageToolTip="Página anteriore" />
<FilterMenu EnableImageSprites="False"></FilterMenu>
<MasterTableView DataKeyNames="DESCRICAO" AllowMultiColumnSorting="false" ShowHeader="true" NoDetailRecordsText="Sem registros para exibir." NoMasterRecordsText="Sem registros para exibir."
ExpandCollapseColumn-ButtonType="ImageButton"
ExpandCollapseColumn-CollapseImageUrl="Library/Imagem/collapse.gif"
ExpandCollapseColumn-ExpandImageUrl="Library/Imagem/expandRed.gif"
ExpandCollapseColumn-HeaderText="Expandir">
<Columns>
<telerik:GridBoundColumn DataField="DESCRICAO" HeaderText="Descrição">
<FooterStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
</Columns>
<NestedViewTemplate>
<asp:Panel runat="server" ID="InnerContainer2" CssClass="viewWrap" Visible="false">
<%--INÍCIO DA GRID RadGrid2--%>
<telerik:RadGrid ID="RadGrid2" runat="server" AllowPaging="True" OnNeedDataSource="RadGrid2_NeedDataSource" Skin="Vista" OnItemDataBound="RadGrid2_ItemDataBound"
AllowSorting="true" AutoGenerateColumns="False" ShowFooter="True">
<SortingSettings SortToolTip="Clique aqui para ordenar" />
<HierarchySettings CollapseTooltip="" ExpandTooltip="Expandir" SelfCollapseTooltip="" SelfExpandTooltip="" />
<ClientSettings EnableRowHoverStyle="true">
<Selecting AllowRowSelect="false" />
<ClientMessages PagerTooltipFormatString="Página <strong>{0}</strong> de <strong>{1}</strong>" />
</ClientSettings>
<GroupPanel Text="">
</GroupPanel>
<PagerStyle FirstPageToolTip="Primeira Página" LastPageToolTip="Ultima Página" NextPagesToolTip="Proximas páginas" NextPageToolTip="Proxima página" PagerTextFormat="Alterar página: {4} &nbsp;Página <strong>{0}</strong> de <strong>{1}</strong>" PageSizeLabelText="Quantidade de Registros:" PrevPagesToolTip="Páginas anteriores" PrevPageToolTip="Página anteriore" />
<FilterMenu EnableImageSprites="False"></FilterMenu>
<MasterTableView AllowMultiColumnSorting="false" ShowHeader="true" NoDetailRecordsText="Sem registros para exibir." NoMasterRecordsText="Sem registros para exibir."
ExpandCollapseColumn-ButtonType="ImageButton"
ExpandCollapseColumn-CollapseImageUrl="Library/Imagem/collapse.gif"
ExpandCollapseColumn-ExpandImageUrl="Library/Imagem/expandRed.gif"
ExpandCollapseColumn-HeaderText="Expandir">
<Columns>
<telerik:GridBoundColumn DataField="DESCRICAO" HeaderText="Descrição">
<FooterStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="VALOR" HeaderText="Valor" DataFormatString="R$ {0:N}">
<FooterStyle Width="80px"></FooterStyle>
<HeaderStyle Width="80px"></HeaderStyle>
<ItemStyle HorizontalAlign="Right" />
<FooterStyle HorizontalAlign="Right" />
</telerik:GridBoundColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>
<%--FIM DA GRID RadGrid2--%>
</asp:Panel>
</NestedViewTemplate>
</MasterTableView>
</telerik:RadGrid>
</asp:Panel>
</NestedViewTemplate>
</MasterTableView>
</telerik:RadGrid>
Respostas
-
Boa tarde, Arthur Moraes. Tudo bem?
Obrigado por usar o fórum MSDN.
Você criou duas threads iguais, então estarei encerrando essa e você segue na thread do link abaixo:Filipe B de Castro
Esse conteúdo é fornecido sem garantias de qualquer tipo, seja expressa ou implícita
MSDN Community Support
Por favor, lembre-se de Marcar como Resposta as postagens que resolveram o seu problema. Essa é uma maneira comum de reconhecer aqueles que o ajudaram e fazer com que seja mais fácil para os outros visitantes encontrarem a resolução mais tarde.
- Marcado como Resposta Filipe B CastroModerator segunda-feira, 23 de abril de 2018 18:39