Tab Control

  • Thread starter Thread starter skumar
  • Start date Start date
S

skumar

I need to add a datagrid in the Tabcontrol which can be
used in common by all Tabpages.

Right now i have to add datagrid to individual tabpages.

Can anyone help me in this. i just want to add one
datagrid control to tabcontrol which can be used and seen
in all tabpages.

Thanks,
SKumar
 
I didnt get the idea behind same datagrid in all pages ?
Could you give the context behind it ?

Kalpesh
 
Why not just place the DataGrid on the parent to the TabControl and then
make sure the z order is properly set so that the DataGrid is in front of
the TabControl. If you really need this as part of your application then
this should be a simple enough solution. So Form1 is the base Form (the base
parent to all other controls). Then place TabControl1 and DataGrid1 as
controls on Form1. Then right-click the DataGrid in the designer and select
"Bring to Front". Now you can position the DataGrid over the TabControl and
give the illusion that as you change TabPage's that the DataGrid is common
to all. And if you need to reposition/resize the DataGrid when the
position/size of the TabControl changes then just handle the LocationChanged
and Resize events for the TabControl.
 
* "skumar said:
I need to add a datagrid in the Tabcontrol which can be
used in common by all Tabpages.

Right now i have to add datagrid to individual tabpages.

Can anyone help me in this. i just want to add one
datagrid control to tabcontrol which can be used and seen
in all tabpages.

Place the datagrid _outside_ the tabpages and set its z-order to show in
front of the pages...
 
Back
Top