Just as we use RowFilter, to choose a subset of rows , i wish to get s
subset of the columns. The workaround i could think of was to read the
DataTable again with only required columns eg - SELECT COL1 FROM DT1 where
DT1 is the memory datatable.
1) Is it possible to apply a SELECT on a DataTable ?
2) How would one pick only the required columns after populating the dataset
?
Regards.
serge calderara - 13 Jan 2006 10:39 GMT
Use the DataView object
> Just as we use RowFilter, to choose a subset of rows , i wish to get s
> subset of the columns. The workaround i could think of was to read the
[quoted text clipped - 7 lines]
>
> Regards.
Cor Ligthert [MVP] - 13 Jan 2006 10:46 GMT
Chak,
For Net 1.x you can use the styles from a datagrid
For Net 2.0 you can beside that use the overloaded version from the
DataView.ToTable to create a seperated datatable.
I hope this helps,
Cor
Miha Markic [MVP C#] - 13 Jan 2006 15:52 GMT
Hi Chak,
Depends on the data consumer as this is a job for UI.
Which one are you using?

Signature
Miha Markic [MVP C#]
RightHand .NET consulting & development www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/
> Just as we use RowFilter, to choose a subset of rows , i wish to get s
> subset of the columns. The workaround i could think of was to read the
[quoted text clipped - 7 lines]
>
> Regards.
Chak - 13 Jan 2006 18:11 GMT
Thanks. Am using the Windows forms datagrid in 1.1
Regards,
Chak.
> Hi Chak,
>
[quoted text clipped - 12 lines]
>>
>> Regards.
Miha Markic [MVP C#] - 14 Jan 2006 08:25 GMT
I never use DataGrid (always a third party grid) as DataGrid is very limited
control.
Anyway, you might read this thread:
http://groups.google.com/group/microsoft.public.dotnet.languages.csharp/browse_f
rm/thread/8256a795d6abc5b4/e8555f595f3bfd2e?lnk=st&q=hide+datagrid+columns+group
%3A*dotnet*&rnum=1&hl=sl#e8555f595f3bfd2e

Signature
Miha Markic [MVP C#]
RightHand .NET consulting & development www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/
> Thanks. Am using the Windows forms datagrid in 1.1
>
[quoted text clipped - 18 lines]
>>>
>>> Regards.
serge calderara - 16 Jan 2006 12:36 GMT
With the datagrid you can filter the column to show by defined Column mapping
Then you mapp only columns you need to show
> Thanks. Am using the Windows forms datagrid in 1.1
>
[quoted text clipped - 18 lines]
> >>
> >> Regards.