title: Print/Import all web page source data using vba
body: <p>I have code below which imports only part of source code into sheet. I want all source code as it is.`Sub GetSourceCode()</p>
  
  <pre><code>Dim ie As Object
  
  Dim str As String
  Dim arr
  
  str = Sheets("sheet2").Range("I1").Value
  Set ie = CreateObject("INTERNETEXPLORER.APPLICATION")
  
  ie.Navigate "https://tiweb.industrysoftware.automation.com/prdata/cgi-bin/n_prdata_index.cgi?"
  ie.Visible = False
  
  Do Until ie.ReadyState = 4
      DoEvents
  Loop
  
  ie.Document.getelementsbyname("pr_numbers")(0).Value = str
  Application.SendKeys ("~")
  
  Do Until ie.ReadyState = 4
      DoEvents
  Loop
  
  
  Worksheets("Download_PRdata2").Activate
  
  arr = Split(ie.Document.body.outertext)
  Worksheets("Download_PRdata2").Activate
  ActiveSheet.Range("A1").Resize(UBound(arr) + 1, 1).Value = Application.Transpose(arr)
  </code></pre>
  
  <p>End Sub`</p>