I have list of ItemFileRecords which contains records like following. I want to find out which records overlap with other record range using LINQ and aslo highlight record which overlap in the grid
SR|File_ID | Item_code | start_page | End_page
01|1 | 4319 | 1 | 10
02|1 | 4321 | 5 | 9
03|1 | 4321 | 11 | 15
04|1 | 4322 | 14 | 19
05|1 | 4323 | 20 |25
06|1 | 4324 | 26 | 30
07|1 | 4325 | 30 | 35
SR|File_ID | Item_code | start_page | End_page
01|1 | 4319 | 1 | 10 (Overlap with rec 2 change color to red)
02|1 | 4321 | 5 | 9 (Overlap with rec 1 change color to red)
03|1 | 4321 | 11 | 15 (Overlap with rec 4 change color to red)
04|1 | 4322 | 14 | 19 (Overlap with rec 3 change color to red)
05|1 | 4323 | 20 |25
06|1 | 4324 | 26 | 30 (overlap with rec 7 change color to red)
07|1 | 4325 | 30 | 35 (overlap with rec 6 change color to red)
I have with nested for loop but want to avoid nested for loop,
If any know any other way to do this can suggest me
Thanks.
Loading
Guest UserPosted Aug 1, 2014, 4:55 AM
syntactically it's similar to LINQ but operates fast.
Ex- these days, we've dual-core or quad-core CPUs. But are we designing softwares where we're enjoying or making merry using these hardware capabilities. I feel not, we're still following linear development approach.
So, if we can identify tasks which can be run independently then we can have our CPU work more efficently and we can get our data output fast.
there are tons of examples of plinq available . so google it...
twitter @sumitjolly
rahul ahujaPosted Jul 31, 2014, 3:02 PM
Guest UserPosted Jul 31, 2014, 6:40 AM