Hector
Thanks for the response.
I'd thought about that previously and it seemed redundant to assigning the DataSource to the datagrid.
So I tried it anyway with the DataSource assignment. Added the TableStyle.MappingName, but I get the same result. I also added assigning a name to ds.Tables[0].Namespace, but same result. I removed the DataSource assignment and get no data in the grid.
DataGridTableStyle ts1 = new DataGridTableStyle();
// New line added
ts1.MappingName = "v_ICPartXML";
Jon
>I think you are missing the MappingName in the TableStyle. You need to indicate the TableStyle the "table" that is bound to.
>Try setting this property just after creating the TableStyle.
>
>
>' VB.NET sample code
>Grid.TableStyles.Clear()
>Dim TableStyle As New System.Windows.Forms.DataGridTableStyle()
>TableStyle.MappingName = TableName
>
>
>