Thanks for the advice, but I did as you suggested and I got back: System.DateTime System.String for TimeNeeded and PurchaseOrderID, respectively. Which is what I expected. Still researching... Any help would be appreciated. Thanks!
LadyReader
Posts
-
custom sorting datatables -
custom sorting datatablesThank you for the help - however I am not getting the results expected. Although ASC is the deafult, I did add ASC to both sort keys: myDataView.Sort = ("PurchaseOrderID ASC, TimeNeeded ASC") Here is a sample of the output, where PurchaseOrderID is column(2) and TimeNeeded is column(9) on a 0 to 11 basis: Row: 119 34028_1_1, 7/25/2005 12:00:00 AM, {unspecified}, , 12345-0003, 1, xxx, 0, , 7/25/2005 12:00:00 AM, M, ------------------------ Row: 120 33734_1_1, 9/11/2005 12:00:00 AM, {unspecified}, , 12346-0002, 1, xxx, 0, , 9/11/2005 12:00:00 AM, M, ------------------------ Row: 121 33597_1_1, 12/12/2012 12:00:00 AM, {unspecified}, , 12345-0001, 1, xxx, 0, , 12/12/2012 12:00:00 AM, M, ------------------------ Row: 122 33596_1_1, 12/12/2012 12:00:00 AM, {unspecified}, , 12345-0001, 1, xxx, 0, , 12/12/2012 12:00:00 AM, M, ------------------------ Row: 123 33596_1_2, 12/12/2012 12:00:00 AM, {unspecified}, , 12345-0001, 2, xxx, 0, , 12/12/2012 12:00:00 AM, M, ------------------------ Row: 124 33597_1_2, 12/12/2012 12:00:00 AM, {unspecified}, , 12344-0001, 2, xxx, 0, , 12/12/2012 12:00:00 AM, M, ------------------------ Row: 125 32798_1_1, 12/31/2029 12:00:00 AM, {unspecified}, , 1234-0003, 2, xxx, 0, , 12/31/2029 12:00:00 AM, M, ------------------------ Row: 126 32412_1_5, 12/31/2029 12:00:00 AM, {unspecified}, , 12345-0002, 3, xxx, 0, , 12/31/2029 12:00:00 AM, M, ------------------------ Row: 127 118121-000, 1/28/2005 12:00:00 AM, {unspecified}, 25, 12345-005, 9, xxx, 0, , 1/28/2005 12:00:00 AM, M, ------------------------ Row: 128 117604-101, 1/13/2005 12:00:00 AM, 147347_020, 540, 12345-1234-006, 1, {unspecified}, 0, 12/22/04, 1/18/2005 12:00:00 AM, P, ------------------------ Row: 129 117749-101, 2/3/2005 12:00:00 AM, 147347_021, 540, 12345-1234-006, 1, {unspecified}, 0, 12/22/04, 2/8/2005 12:00:00 AM, P, ------------------------ Row: 130 117941-101, 3/9/2005 12:00:00 AM, 150236_005, 105, 12345-001, 10500, {unspecified}, 0, 03/07/05, 1/19/2005 12:00:00 AM, M, ------------------------ Row: 131 118122-000, 1/26/2005 12:00:00 AM, {unspecified}, 20, 12345-004, 12, xxxx, 0, , 1/26/2005 12:00:00 AM, M, ------------------------ Row: 132 118110-000, 12/20/2004 12:00:00 AM, {unspecified}, 20, 12345-003, 5, xxxx, 0, , 12/9/2004 12:00:00 AM, M, ------------------------ Take a look at rows 126 and 127 - although PurchaseOrderID has been {unspecified} through this point, TimeNeeded has jumped backwards from 12/31/2029 to 1/28/2005. The