Hello:
I have a DataGridView with columns, that if double clicked can be sorted.
I am using Typed DataSets.
Below is a partial example of code:
The result is some date columns. Yet when I click to sort them, they are sorted not by the date, but by their value. Both the database and the .NET variables are Date fields.
ie:
The illustration below is what happens when I double click the ShipDate column in the DataGridView. You can see that it is not sorted by date but by the string value.
![Name: 2021-07-26 13_42_17-Form2.bmp
Views: 32
Size: 92.1 KB]()
How can I make this work?
I have a DataGridView with columns, that if double clicked can be sorted.
I am using Typed DataSets.
Below is a partial example of code:
Code:
Dim ta_JobInfo As JobSheetDataSetTableAdapters.JobInfoTableAdapter = New JobSheetDataSetTableAdapters.JobInfoTableAdapter
ta_JobInfo.Fill(JobSheetDataSet1.JobInfo)
Dim row_JobInfo_read As JobSheetDataSet.JobInfoRow = JobSheetDataSet1.JobInfo.FindByJobNo(_JobNo)
With row_JobInfo_read
JobNo = .JobNo
Product = .Product
Detail = .Detail
DRAWINGNO = .DrawingNo
Started = .Started ' Date
Completed = .Completed ' Date
Engineer = .Engineer
Designer = .Designer
Checker = .Checker
EstHrs = CStr(.EstHrs) ' Decimal
ShipTo = .ShipTo
ShipDate = .ShipDate ' Date
FMLDrawingNo = .FMLDrawingNo
End With
ie:
Code:
Dim Started As Date
Dim Completed As Date
Dim ShipDate As Date
How can I make this work?