Created
May 12, 2020 04:20
-
-
Save compil3/55ec131f762584fdd331ead274ac8a13 to your computer and use it in GitHub Desktop.
Linq Nodes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IEnumerable<List<string>> table = playerDoc.DocumentNode | |
.SelectSingleNode($"//*[@id='lg_team_user_leagues-{leagueId}']/div[4]/table/tbody") | |
.Descendants("tr") | |
.Skip(1) | |
.Where(tr => tr.Elements("td").Count() > 1) | |
.Select(tr => tr.Elements("td").Select(td => td.InnerText.Trim()) | |
.Where(td => td.Contains("Reg")).ToList()) | |
.ToList(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment