.NET Framework Developer Center > .NET Development Forums > JScript for the .NET Framework > How Do I Get The Entire HTML Source After DocumentComplete?
Ask a questionAsk a question
 

AnswerHow Do I Get The Entire HTML Source After DocumentComplete?

  • Thursday, November 05, 2009 2:18 PMmagnets Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I use InternetExplorer.Application and after the DocumentComplete event is complete I want to retrieve the entire HTML source.  How do I do that?

    I've already retrieved some of the source using innerHTML, outerHTML.  innerText was empty.  I was also able to retrieve some data using variations of Document.documentElement

    If Microsoft has not figured out an easy way to retrieve the entire source yet, does Microsoft provide a method to retrieve the temporary file name for the web page?  In that way I could just read the file and retrieve the source.

    This has got to be a lot easier than my meager attempts have produced so far.
    Always Microsoft Problems

Answers

  • Thursday, November 05, 2009 3:47 PMmagnets Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Try the Document.documentElement.OuterHTML property of the web browser


    Ganesh Ranganathan
    [Please mark the post as answer if it answers your question]
    blog.ganeshzone.net

    "outerHTML" works.  "OuterHTML" does not work.

    Thanks for making me try "outerHTML" once again.  I previously tried it in the NavigateComplete2 event.  After I started using the DocumentComplete event I never got back to testing "outerHTML".

    Thanks again!


    Always Microsoft Problems
    • Marked As Answer bymagnets Thursday, November 05, 2009 3:49 PM
    •  

All Replies

  • Thursday, November 05, 2009 2:52 PMGanesh Ranganathan - Bangalore, India Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Try the Document.documentElement.OuterHTML property of the web browser


    Ganesh Ranganathan
    [Please mark the post as answer if it answers your question]
    blog.ganeshzone.net
  • Thursday, November 05, 2009 3:47 PMmagnets Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Try the Document.documentElement.OuterHTML property of the web browser


    Ganesh Ranganathan
    [Please mark the post as answer if it answers your question]
    blog.ganeshzone.net

    "outerHTML" works.  "OuterHTML" does not work.

    Thanks for making me try "outerHTML" once again.  I previously tried it in the NavigateComplete2 event.  After I started using the DocumentComplete event I never got back to testing "outerHTML".

    Thanks again!


    Always Microsoft Problems
    • Marked As Answer bymagnets Thursday, November 05, 2009 3:49 PM
    •