Your parentheses are in the wrong place:
comment = string.Join(Environment.NewLine,
dtModified.AsEnumerable()
.Where(p => ...)
.Select(a => a.Field(Constants.Time))
) + "LL:" + LowLevel + "," + "Value:" + Value + "," + "HL:" + HighLevel;
Move the additional information inside the
Select
projection:
comment = string.Join(Environment.NewLine,
dtModified.AsEnumerable()
.Where(p => ...)
.Select(a => a.Field(Constants.Time) + "LL:" + LowLevel + "," + "Value:" + Value + "," + "HL:" + HighLevel)
);