"Realtime" Displaying of HTML in CWebBrowser2
-
I generate HTML reports that can be over 100,000 lines long. I then view them in a CWebBrowser2 control. Sometimes to generate these 100,000 line reports take 20 minutes on a fast PC, so what I would like to do is to display the report as it is being generated. No or tag will be seen until the end, and this does not seem to matter. I have tried just calling "reload" every ten second, but as the report gets bigger this does tend to slow down display a lot when reloading. Does anyone know a way I could whatch the report being generated character by character without having to press reload please? In other words everytime my HTML report changes I would like to see the change displayed in my CWebBrowser2 control, however I don't want to reload the entire HTML report each time such a change is detected.... Thanks for any help at all. Jerry
-
I generate HTML reports that can be over 100,000 lines long. I then view them in a CWebBrowser2 control. Sometimes to generate these 100,000 line reports take 20 minutes on a fast PC, so what I would like to do is to display the report as it is being generated. No or tag will be seen until the end, and this does not seem to matter. I have tried just calling "reload" every ten second, but as the report gets bigger this does tend to slow down display a lot when reloading. Does anyone know a way I could whatch the report being generated character by character without having to press reload please? In other words everytime my HTML report changes I would like to see the change displayed in my CWebBrowser2 control, however I don't want to reload the entire HTML report each time such a change is detected.... Thanks for any help at all. Jerry
Hi Jerry Heres a different approach :-) First Navigate to about:blank then 1. Use "mshtml" to insert some dummy tags, 2. Now as your app exports the HTML take it as a string and use { insertAdjacentHTML (,"BeforeEnd") } to put your HTML into the control now automate the scroll mechananism probably { scrollto }to scroll to the bottom of the new HTML Continue this until you get to the end. Regardz
-
Hi Jerry Heres a different approach :-) First Navigate to about:blank then 1. Use "mshtml" to insert some dummy tags, 2. Now as your app exports the HTML take it as a string and use { insertAdjacentHTML (,"BeforeEnd") } to put your HTML into the control now automate the scroll mechananism probably { scrollto }to scroll to the bottom of the new HTML Continue this until you get to the end. Regardz
Thanks I'll try just that....