How to Programmatically create a DataGrid

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • ad

    How to Programmatically create a DataGrid

    I use the code to create a DataGrid and filled with data,
    But the DataGrid1 didn't display in WebForm.
    How can I display the DataGrid after creating it?



    DataGrid DataGrid1 = new DataGrid();


  • jabailo@texeme.com

    #2
    Re: How to Programmaticall y create a DataGrid

    ad wrote:[color=blue]
    > I use the code to create a DataGrid and filled with data,
    > But the DataGrid1 didn't display in WebForm.
    > How can I display the DataGrid after creating it?
    >
    >
    >
    > DataGrid DataGrid1 = new DataGrid();
    >
    >[/color]


    An Extensive Examination of the DataGrid Web Control: Part 1

    Comment

    • ad

      #3
      Re: How to Programmaticall y create a DataGrid

      Thank!
      But I can't find about Programmaticall y create a DataGrid in that article!

      <jabailo@texeme .com> ???????:42B77B4 9.9000101@texem e.com...[color=blue]
      > ad wrote:[color=green]
      > > I use the code to create a DataGrid and filled with data,
      > > But the DataGrid1 didn't display in WebForm.
      > > How can I display the DataGrid after creating it?
      > >
      > >
      > >
      > > DataGrid DataGrid1 = new DataGrid();
      > >
      > >[/color]
      >
      > http://aspnet.4guysfromrolla.com/articles/040502-1.aspx
      > An Extensive Examination of the DataGrid Web Control: Part 1[/color]


      Comment

      • jabailo@texeme.com

        #4
        Re: How to Programmaticall y create a DataGrid


        Well, its the first block of sample code on the first page.

        Just scroll down and it's right there.

        If you can't understand that, then you need to really do some basic reading
        in .Net before asking these kinds of questions.


        ad wrote:
        [color=blue]
        > Thank!
        > But I can't find about Programmaticall y create a DataGrid in that article!
        >
        > <jabailo@texeme .com> ???????:42B77B4 9.9000101@texem e.com...[color=green]
        >> ad wrote:[color=darkred]
        >> > I use the code to create a DataGrid and filled with data,
        >> > But the DataGrid1 didn't display in WebForm.
        >> > How can I display the DataGrid after creating it?
        >> >
        >> >
        >> >
        >> > DataGrid DataGrid1 = new DataGrid();
        >> >
        >> >[/color]
        >>
        >> http://aspnet.4guysfromrolla.com/articles/040502-1.aspx
        >> An Extensive Examination of the DataGrid Web Control: Part 1[/color][/color]

        --
        Texeme Textcasting Technology

        Comment

        • ad

          #5
          Re: How to Programmaticall y create a DataGrid

          Thank!
          But I can't find about Programmaticall y create a DataGrid in that article!

          <jabailo@texeme .com> ???????:42B77B4 9.9000101@texem e.com...[color=blue]
          > ad wrote:[color=green]
          > > I use the code to create a DataGrid and filled with data,
          > > But the DataGrid1 didn't display in WebForm.
          > > How can I display the DataGrid after creating it?
          > >
          > >
          > >
          > > DataGrid DataGrid1 = new DataGrid();
          > >
          > >[/color]
          >
          > http://aspnet.4guysfromrolla.com/articles/040502-1.aspx
          > An Extensive Examination of the DataGrid Web Control: Part 1[/color]


          Comment

          • jabailo@texeme.com

            #6
            Re: How to Programmaticall y create a DataGrid


            Well, its the first block of sample code on the first page.

            Just scroll down and it's right there.

            If you can't understand that, then you need to really do some basic reading
            in .Net before asking these kinds of questions.


            ad wrote:
            [color=blue]
            > Thank!
            > But I can't find about Programmaticall y create a DataGrid in that article!
            >
            > <jabailo@texeme .com> ???????:42B77B4 9.9000101@texem e.com...[color=green]
            >> ad wrote:[color=darkred]
            >> > I use the code to create a DataGrid and filled with data,
            >> > But the DataGrid1 didn't display in WebForm.
            >> > How can I display the DataGrid after creating it?
            >> >
            >> >
            >> >
            >> > DataGrid DataGrid1 = new DataGrid();
            >> >
            >> >[/color]
            >>
            >> http://aspnet.4guysfromrolla.com/articles/040502-1.aspx
            >> An Extensive Examination of the DataGrid Web Control: Part 1[/color][/color]

            --
            Texeme Textcasting Technology

            Comment

            • ad

              #7
              Re: How to Programmaticall y create a DataGrid

              Thanks,
              You mean the line:
              <asp:datagrid runat="server" id="ID_of_DataG rid" />


              It is design time created DataGrid, but I wnat to know how to create it
              dynamically!




              <jabailo@texeme .com> ???????:iMidnaL g8Yc3KSrfRVn-gw@speakeasy.ne t...[color=blue]
              >
              > Well, its the first block of sample code on the first page.
              >
              > Just scroll down and it's right there.
              >
              > If you can't understand that, then you need to really do some basic[/color]
              reading[color=blue]
              > in .Net before asking these kinds of questions.
              >
              >
              > ad wrote:
              >[color=green]
              > > Thank!
              > > But I can't find about Programmaticall y create a DataGrid in that[/color][/color]
              article![color=blue][color=green]
              > >
              > > <jabailo@texeme .com> ???????:42B77B4 9.9000101@texem e.com...[color=darkred]
              > >> ad wrote:
              > >> > I use the code to create a DataGrid and filled with data,
              > >> > But the DataGrid1 didn't display in WebForm.
              > >> > How can I display the DataGrid after creating it?
              > >> >
              > >> >
              > >> >
              > >> > DataGrid DataGrid1 = new DataGrid();
              > >> >
              > >> >
              > >>
              > >> http://aspnet.4guysfromrolla.com/articles/040502-1.aspx
              > >> An Extensive Examination of the DataGrid Web Control: Part 1[/color][/color]
              >
              > --
              > Texeme Textcasting Technology
              > http://www.texeme.com[/color]


              Comment

              Working...