Customized Datagrid

Hema Rawat

Member
Joined
Dec 12, 2005
Messages
24
Location
India
Programming Experience
1-3
Hey all,

I want to add the the template columns in my Winforms Datagrid
But know the concept behind this.(as new to vb.net)

I have add a Datetimepicker control in 2nd column of datagrid
& ComboBox(MultiColumn) in the 3rd Column of the datagrid

How to add the other Controls in datagrid Columns

Any COde Source , sample link about the Datagrid are welcome

Thanks a lot for this help
 
Datetimepicker in Grid

Adding Datetimepicker in a datagrid add the code as below

Dim dataset1 As New DataSet
Dim datatable1 As New DataTable
datatable1.TableName = "Inspection Details"
Dim dgdtblStyle As New DataGridTableStyle
dgdtblStyle.MappingName = "Inspection Details"

Dim col4 As New DataGridTextBoxColumn

colDataTypes.MappingName = "Date"
colDataTypes.HeaderText = "Date"
colDataTypes.Width = 120
colDataTypes.ReadOnly =
True
AddHandler colDataTypes.TextBox.Enter, AddressOf SetDateDataTypes
dgdtblStyle.GridColumnStyles.Add(colDataTypes)



Dim dataColumn3 As New DataColumn

dataColumn3.ColumnName = "Date"
dataColumn3.DefaultValue = ""
datatable1.Rows(k).Item(3) = dtSample1.Rows(i).Item("RakeInsDetail_Date")

 
Datetimepicker in DataGrid

Hey
Thanks for this Kind Support.
I will apply this way
thanks for the direction.


Thanks & Regards
Hema Chaudhry
 
Back
Top