I use the lamda expression to filter the request.
Basically, I have lines consisting of segments, and these segments are marked as deleted, inserted, or null.
What I want to return are segments marked as deleted, but whose sibling is NOT marked as deleted. As an example,
Line: "Soylent Green is people!" Broken into 2 segments... Segment 1: "Soylent Green " (marked as deleted) Segment 2: "is people!" (not marked as deleted)
Should return segment 1 to me. But the following example
Line: "Open the pod bay doors Hal!" Broken into 3 segments... Segment 1: "Open the " (marked as deleted) Segment 2: "pod bay " (marked as deleted) Segment 3: "doors Hal!" (marked as deleted)
No need to return segments. See the following code:
return seg => seg.ModType == Deleted && seg.Line.Segments.Any(segs => segs.ID != seg.ID && segs.ModType != Deleted);
Thanks, and I appreciate any help or suggestion as to why this is not working.
Jaime source share