Answer the question
In order to leave comments, you need to log in
How to parse a number from HTML using C#?
Hello.
On this site: MICEX
, the volume of transactions is "147,354,466,820" in rubles. I need to parse this number. How can this be done in C#?
PS It is worth considering that when you press the Ctrl+U key combination in any browser, this number is not displayed in the HTML code.
Answer the question
In order to leave comments, you need to log in
This is an Angular page and the value is a bindig, which, for example, can make some other request to get the result. In general, if you receive a page with a request via HtmlClient (well, or RestSharp), then you will receive a page with raw js scripts, they must be executed on the client side in the browser after the page is loaded. Therefore, you will get {{column.getValue(item)}}, but if the browser receives this result, it will execute the scripts and there will be a value.
In general, the solution may be to load the page, for example, through Selenium (WebDriver) or through Phantom and get the value from them.
Here is another option . I have not tried it, but they write that you can run js code this way, try it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question