← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #151213]: save captured screen or image on hard disk

 

Question #151213 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/151213

    Status: Open => Answered

Anshu proposed the following answer:
Hi Vishal,
I am using something like this - when i take a screen capture - incase my test fails.
YOU can modify it as per your needs.

In my sikuli script , i have

m=capture(1,1,1020,900)
sName = sWorkingDir +  sFileName+".png"   # you can give values to these variables
shutil.copy(m,sName)   # you need to import shutil in the beginning of your script

So this will copy the image file in your directory with whatever name
you pass to it..

Hope that helps.
Anshu

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.