Forum Discussion
rmanning
16 years agoContributor
Figured it out:
To save a screenshot:
Sys.Desktop.Picture.SaveToFile "C:\TEMP\Desktop.jpg"
To email saved screenshot:
If SendMail("ClareJ@clarejeffersoncorp.com", "mail.johnsmithcorp.com", "John Smith", "JohnS@johnsmithcorp.com", "Notification", "Hello Clare, Your application is nice.", "C:\TEMP\Desktop.jpg") Then
Log.Message "Mail was sent"
Else
Log.Warning "Mail was not sent"
End If
My only question now is how to take multiple/incremental screenshots instead of overwriting the same file every time.. So like a "Desktop1.jpg", "Desktop2.jpg", etc. Any suggestions? I'll keep digging...
To save a screenshot:
Sys.Desktop.Picture.SaveToFile "C:\TEMP\Desktop.jpg"
To email saved screenshot:
If SendMail("ClareJ@clarejeffersoncorp.com", "mail.johnsmithcorp.com", "John Smith", "JohnS@johnsmithcorp.com", "Notification", "Hello Clare, Your application is nice.", "C:\TEMP\Desktop.jpg") Then
Log.Message "Mail was sent"
Else
Log.Warning "Mail was not sent"
End If
My only question now is how to take multiple/incremental screenshots instead of overwriting the same file every time.. So like a "Desktop1.jpg", "Desktop2.jpg", etc. Any suggestions? I'll keep digging...