Hi all,
I created two windows forms where in first I collected all data in several datatables and put each data in tab control using datagridview:
In First Form I inserted this code:

Code:
Output_Form2.t1 = New TabControl

        Output_ Form2.mytabPage = New TabPage
        Output_ Form2.t1.Dock = DockStyle.Fill
        grid.Dock = DockStyle.Fill
        Output_Form2.TableLayoutPanel1.Controls.Add(Output_Form2.t1)
        Output_Form2.TableLayoutPanel1.Location = New System.Drawing.Point(0, 0)

        grid.DataSource = table_Form2_UtranCell
        Output_Form2.mytabPage.Controls.Add(grid)
        Output_Form2.t1.Controls.Add(Output_Form2.mytabPage)
        Output_Form2.mytabPage.Text = "UUtranCellFDD"
        grid.RowHeadersVisible = True
In second Form and exactly when I load the form I reported following code:

Code:
For z = 1 To t1.TabPages.Count
            SelectedGrid = New DataGridView
For Each ctl As Control In t1.TabPages(z - 1).Controls                 	
           If TypeOf ctl Is DataGridView Then
                    t1.TabPages(z - 1).Select()
                    SelectedGrid = ctl

                    Dim cc = t1.TabPages(z - 1).Text
                    Dim rowNumber As Integer = 1
                    
                    For i = 0 To SelectedGrid.RowCount - 1
                        SelectedGrid.Rows(i).HeaderCell.Value = CStr(i + 1)
                    Next
            End If

        Next
 Next
But I visualized cell number only in the first tab page and not in the other ones but I don't understand why.

Can you help me?
Thanks in advacend
gio