Click here to Skip to main content
15,910,121 members
Please Sign up or sign in to vote.
1.00/5 (4 votes)
See more:
I am Using below CODE DGV HeaderText Purpose..
VB
Dim strSQL7 As String = "SELECT STUFF((SELECT DISTINCT '],['+ [FeesType] FROM FeeMaster WHERE Class='" & cboClass.Text & "' ORDER BY '],[' + [FeesType]  For XML Path('')), 1, 2,'') + ']' "
      Dim DaAp7 As New SqlDataAdapter(strSQL7, con)
        Dim Dset7 As New DataTable
        DaAp7.Fill(Dset7)
       
        With Me.DataGridView2
            .Columns.Add("Regno", "RegNo")
            .Columns.Add("Sname", "Name")
            .Columns.Add(0, Dset7.Rows(0).Item("Column1"))
           .Columns.Add("", "Total")
        End With


Wht is my Error : Team1 and Team-2 Show to Column3

Regno Name [Team-1],[Team-2] Total

i Need Seperate Team1 and Team2 Like

Regno Name Team-1 Team-2 Total

Please Tell me how can i do for Seperate
Posted
Updated 14-Feb-13 7:59am
v2
Comments
Richard C Bishop 14-Feb-13 14:13pm    
What do you mean "What is my error"? That is what you are supposed to tell us. Are you getting an error message? Are you getting results you do not expect? Are you not getting any results at all? Does your code compile? Have you debugged it?
Navas Khanj 14-Feb-13 14:15pm    
DGV headertext want to display colum3 seperate
Ashok19r91d 15-Feb-13 7:39am    
Try This...
With Me.DataGridView2
.Columns.Add("Regno", "RegNo")
.Columns.Add("Sname", "Name")
.Columns.Add("Col1", Dset7.Rows(0).Item("Column1"))
.Columns.Add("", "Total")
End With
Navas Khanj 15-Feb-13 9:39am    
It's not Work For Seperate

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900