How can I add different columns with same name to gridview???

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ajish Antony
    New Member
    • Feb 2010
    • 3

    How can I add different columns with same name to gridview???

    I am using C#.Net as my language. I want to add some columns of same name to a grid view. How can I do it???
  • tlhintoq
    Recognized Expert Specialist
    • Mar 2008
    • 3532

    #2
    Read about the gridview control in MSDN. Sample code and all.
    Displays the values of a data source in a table where each column represents a field and each row represents a record. The GridView control enables you to select, sort, and edit these items.

    Comment

    • Frinavale
      Recognized Expert Expert
      • Oct 2006
      • 9749

      #3
      You cannot add different columns with the same name to a GridView.
      You have to give each column a unique name.

      What are you trying to accomplish?

      -Frinny

      Comment

      • Ajish Antony
        New Member
        • Feb 2010
        • 3

        #4
        Thank you all for your help.

        I managed it by using a space(" ") with the column name. Now it is working properly.
        Thanks to everyone.

        Comment

        Working...