Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Web2Image
#17
I found a good solution, please use QM to execute the following powershell script Smile ​​​​​​​

 
Code:
Copy      Help
 
$ie = New-Object -ComObject InternetExplorer.Application

$ie.Visible = $true;

$Yourwebpage = $ie.navigate('www.msn.com')

while($Yourwebpage.Busy){Start-Sleep -Seconds 5}

#capturing the screenshot

$file = "C:\Users\xyz\Desktop\abc\$(Get-Date -Format dd-MM-yyyy-hhmm).bmp"

Add-Type -AssemblyName System.Windows.Forms

Add-type -AssemblyName System.Drawing

$Screen = [System.Windows.Forms.SystemInformation]::VirtualScreen

$width = $Screen.width

$Height = $Screen.Height

$Left = $Screen.Left

$Right = $Screen.Right

$Top = $Screen.Top

$Bottom = $Screen.Bottom

$bitmap = New-Object System.Drawing.Bitmap $width, $Height

$Graphics = [System.Drawing.Graphics]::FromImage($bitmap)

$Graphics.CopyFromScreen($Left, $Top, 0, 0, $bitmap.Size)

$bitmap.Save($File)

Write-Output "Screenshot saved to:"

Write-Output $File


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)