Editing in nested datagrids - ASP.NET and VB

Discussion in 'ASP .Net Web Controls' started by subha, Jul 10, 2003.

  1. subha

    subha Guest

    Hi All

    I am trying to nest a datagrid inside a repeater control. I find
    problems editing the datagrid. The code is attached below. All
    examples that I read in the web involved code-behind concepts which i
    am not very aware of.

    Any help on this subject would be highly appreciated.

    Thanks
    Subha

    HTML…
    <asp:Repeater id="rptCat" runat="server">
    <ItemTemplate>
    <%# Container.DataItem("ItemCategoryName")%>
    <asp:Repeater DataSource='<%# FilterCat(
    Container.DataItem("ItemCategoryID") )%>' RunAt ="Server" >
    <ItemTemplate>
    <%# Container.DataItem("ItemSubCategoryName") %>
    <asp:DataGrid DataSource='..' id="dgrdContents"
    OnEditCommand="dgrdContents_EditCommand"
    OnUpdateCommand="dgrdContents_Updatecommand"
    OnCancelCommand="dgrdContents_CancelCommand" Runat="Server">
    <Columns>
    …..
    </Columns>
    </asp:DataGrid>
    </ItemTemplate>
    </asp:Repeater>
    </ItemTempllate>
    </asp:Repeater>

    VB Code part…
    Sub dgrdContents_EditCommand( s As Object, e As
    DataGridCommandEventArgs )
    dgrdContents.EditItemIndex = e.Item.ItemIndex
    BindDataGrid
    End Sub

    I get the following error…
    Compiler Error Message: BC30451: Name 'dgrdContents' is not declared.
     
    subha, Jul 10, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mike Moore [MSFT]

    RE: 'Overall' Editing DataGrids

    Mike Moore [MSFT], Nov 11, 2003, in forum: ASP .Net
    Replies:
    2
    Views:
    504
    Mike Moore [MSFT]
    Nov 12, 2003
  2. Sebi

    Overall editing DataGrids

    Sebi, Nov 12, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    347
  3. David Lozzi

    SQL, XML, Nested Datagrids and the like

    David Lozzi, Oct 7, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    383
    Frankie
    Oct 7, 2005
  4. Replies:
    0
    Views:
    601
  5. dew

    Editing datagrids & scrolling problem

    dew, Feb 14, 2006, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    129
Loading...

Share This Page