I want to parse a site's pages programmatically, and obviously I need to have full HTML code. However, a site can load only some master-page via direct URL, and once the master-page is loaded, it then receives its content via AJAX.
How could I load a page "like in a browser" to let it be loaded completely with all its scripts having their work done?
For example, if I use WebBrowser class to really open a page "like in a browser", its DocumentText property (which should represent DOM contents) only returns initial page without actual contents loaded via AJAX or like that (tested on google.com). That happens in a browsers too, and to see actual HTML I need to use developer tools.
UPDATED: the answer is found to be here, thanks to Vladimir Shmidt how to dynamically generate HTML code using .NET's WebBrowser or mshtml.HTMLDocument?
DocumentText isn't updating its contents after the "root" DOM was loaded, but Document property does.