Sign in to follow this  
Followers 0
qwertylol

how do I name of screenshot?

12 posts in this topic

Do

_ScreenCap_Capture( $name , 0, 0, 300, 150, False)

Sleep (2000)

Until $loop = 200

$name should be = " screenshot & $loop "

Share this post


Link to post
Share on other sites



For $i = 1 To 200
    _ScreenCap_Capture ("screenshot-" & $i, 0, 0, 300, 150, False)
    Sleep(2000)
Next


[size="1"][font="Arial"].[u].[/u][/font][/size]

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

For $i = 1 To 200
    _ScreenCap_Capture ("screenshot-" & $i, 0, 0, 300, 150, False)
    Sleep(2000)
NextoÝ÷ Úâ*.Á©í¶¦Û«y©h¶ìr·Èh¶Ì¨¹Ê.Û¶êZd{+h{­Ê«±Êâ¦Ö§vØ^Ú,¢g­)à)¶¬jëh×6Global $iCount
while 1
  $iCount += 1
  _ScreenCap_Capture ("screenshot-" & $iCount & ".jpg", 0, 0, 300, 150, False)
  Sleep(2000)
wend
Edited by PaulIA

Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

yeah, i am doing data mining for the OCR thing.

Share this post


Link to post
Share on other sites

opps,

what's the file name is to include?

is it

#include auto3lib.au3 ?

Share this post


Link to post
Share on other sites

got it in the help file.

#include <A3LScreenCap.au3>

Share this post


Link to post
Share on other sites

I ran this

#include <A3LScreenCap.au3>


MsgBox (0, "go","mining")
Dim $loop = 0

Do 

  _ScreenCap_Capture ("screenshot-" & $loop & ".jpg", 0, 0, 300, 150, False)
  Sleep(2000)
    $loop = $loop + 1
Until 


MsgBox (0, "done","enough")

and the error message is:

problem.bmp

Share this post


Link to post
Share on other sites

I ran this

#include <A3LScreenCap.au3>
MsgBox (0, "go","mining")
Dim $loop = 0

Do 

  _ScreenCap_Capture ("screenshot-" & $loop & ".jpg", 0, 0, 300, 150, False)
  Sleep(2000)
    $loop = $loop + 1
Until 
MsgBox (0, "done","enough")

and the error message is:

This script doesn't compile, so it can't be what you are running. Make sure you have the latest beta (or RC) of AutoIt installed.

Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

This works:

#include <A3LScreenCap.au3>

HotKeySet("{ESC}", "DoExit")

Global $iIndex=0

while 1
  _ScreenCap_Capture ("screenshot-" & $iIndex & ".jpg", 0, 0, 300, 150, False)
  Sleep(2000)
  $iIndex += 1
wend

Func DoExit()
  Exit
EndFunc
Edited by PaulIA

Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

#10 ·  Posted

Actually, you need an extension so that the function will know what format to save the screen shot. Could be BMP, GIF, JPG, PNG or TIF:...

Yeah, I should have either tested what I posted or mentioned the caveat that I had never used the UDF.

...and then there was the whole Global thing that I should have caught.

Thanks.


[size="1"][font="Arial"].[u].[/u][/font][/size]

Share this post


Link to post
Share on other sites

#11 ·  Posted

I think it's important that maybe you can have a version of auto3lib that work with the stable version.

Not that I am saying my time is too valuable, but my ability just limits me to dealing with only so much problems.

:)

Share this post


Link to post
Share on other sites

#12 ·  Posted

how do I write this one?

Run ( "mspaint.exe problem 'screenshot' & $i & '.jpg'.bmp" )

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0