Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using CSQuery
- class Scraper
- {
- static async Task Main()
- {
- //..
- {
- //...
- // Load the HTML content into CsQuery
- CQ dom = CQ.Create(htmlContent);
- // Find the stock amount element using a CSS selector
- CQ stockElement = dom.Find(".stock");
- // Extract the stock amount text
- string stockAmount = stockElement.Text();
- Console.WriteLine("Stock Amount: " + stockAmount);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement