Sign in to follow this  
Followers 0

***remote Pc Control***

105 posts in this topic




#23 ·  Posted (edited)

How do you make a screen capture script?

I made a script like yours thanks to you and i added something like run program and type text!

;):D:D:(:):think:

I add this:

Case $gettext[1] = "screen"
    DllCall("captdll.dll", "int", "CaptureScreen", "str", @TempDir & "\PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, '/gallery/SC.jpg')
    $Ftpp = _FtpPutFile($Conn, @TempDir & '\PS.jpg', '/gallery/SC.jpg')
    Return "Screen Captured "

You will need this and this

but for some reason, the FTP does not replace the original file. any ideas, the Screen cap works so i has to be the FTP

I also add this directory return that is great.

just add this in

Case $gettext[1] = "dir"
    Dim $dir
    _ArrayDelete($gettext, 0)
    $directory = _ArrayToString ( $gettext, "*" )
    $directory = StringReplace($directory, "dir*", "")
    $directory = StringReplace($directory, "\\", "\")
    $search = FileFindFirstFile($directory)
    $dir = _ArrayCreate("")
If $search = -1 Then
    Return "No files/directories matched the search pattern"
EndIf
While 1
    $file = FileFindNextFile($search) 
    If @error Then ExitLoop
    _ArrayAdd ( $dir, $file )
WEnd
FileClose($search)
$dirout = _ArrayToString ( $dir, "&" )
$dirout = StringReplace( $dirout, "&", "<br>" )
Return "Files in folder: " & $directory & "<br>" & $dirout & "<BR><BR>Directory listed "

If that was you on there, sorry for sounding so mean, it just bothers me when out of the blue I hear people messing with this.

Please do not use this off of my site, open your own account and use this because I use this too, Thank You

Edited by zerocool60544

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#25 ·  Posted

whatever happened to the arm? did you ever follow up on that?


The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN

Share this post


Link to post
Share on other sites

#26 ·  Posted

whatever happened to the arm? did you ever follow up on that?

oh yeah, I have it all done exept the arm I got lazy because the movments were slow reacting because of the gears, I will hook it up really quick and make a quick scipt for it, but there is no claw on it, there are three axies though

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#28 ·  Posted

Zerocool,

Why is the Screen capture slow??????????

because it has to upload it to teh webserver.

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#29 ·  Posted

zerocool60544, would you please send me the inet.au3 file you have, mine doesn't work.

email:jacksont123fs@gmail.com

or just pm me

thanks a lot!


Share this post


Link to post
Share on other sites

#30 ·  Posted

zerocool60544, would you please send me the inet.au3 file you have, mine doesn't work.

email:jacksont123fs@gmail.com

or just pm me

thanks a lot!

You could probably get it here: ( http://www.autoitscript.com/forum/index.php?showtopic=19717 )

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#31 ·  Posted

I add this:

Case $gettext[1] = "screen"
    DllCall("captdll.dll", "int", "CaptureScreen", "str", @TempDir & "\PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, '/gallery/SC.jpg')
    $Ftpp = _FtpPutFile($Conn, @TempDir & '\PS.jpg', '/gallery/SC.jpg')
    Return "Screen Captured "

You will need this and this

but for some reason, the FTP does not replace the original file. any ideas, the Screen cap works so i has to be the FTP

i tried to modify it to work on your old pc control server: http://www.autoitscript.com/forum/index.ph...pic=20094&st=30

i tried this and it did take a screenshot which is saved in a local dir, but when it uploads it, the file is there but the size is 0 bytes :)

Case StringInStr ($con, "screenshot") > 0
    DllCall("captdll.dll", "int", "CaptureScreen", "str", "gallery/PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, 'PS.jpg')
    $Ftpc = _FTPClose($Open)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    $Ftpp = _FtpPutFile($Conn, 'PS.jpg', 'PS.jpg')
    $Ftpc = _FTPClose($Open)

Share this post


Link to post
Share on other sites

#32 ·  Posted

i tried to modify it to work on your old pc control server: http://www.autoitscript.com/forum/index.ph...pic=20094&st=30

i tried this and it did take a screenshot which is saved in a local dir, but when it uploads it, the file is there but the size is 0 bytes :)

Case StringInStr ($con, "screenshot") > 0
    DllCall("captdll.dll", "int", "CaptureScreen", "str", "gallery/PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, 'PS.jpg')
    $Ftpc = _FTPClose($Open)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    $Ftpp = _FtpPutFile($Conn, 'PS.jpg', 'PS.jpg')
    $Ftpc = _FTPClose($Open)
The only thing I can think of is that it is not uploading the right file so it just creates the file.

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#33 ·  Posted (edited)

The only thing I can think of is that it is not uploading the right file so it just creates the file.

Case StringInStr ($con, "screenshot") > 0
    DllCall("captdll.dll", "int", "CaptureScreen", "str", "PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, 'PS.jpg')
    $Ftpc = _FTPClose($Open)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    $Ftpp = _FtpPutFile($Conn, 'PS.jpg', 'PS.jpg')
    $Ftpc = _FTPClose($Open)

i think i fixed it because it was in fact in the wrong directory

but it still is at 0 bytes :)

is the code right?

Edited by The Great 'Awesoma-Powa!'

Share this post


Link to post
Share on other sites

#34 ·  Posted

Case StringInStr ($con, "screenshot") > 0
    DllCall("captdll.dll", "int", "CaptureScreen", "str", "PS.jpg", "int", 40)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    _FTPDelFile($Conn, 'PS.jpg')
    $Ftpc = _FTPClose($Open)
    $Open = _FTPOpen('MyFTP Control')
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    $Ftpp = _FtpPutFile($Conn, 'PS.jpg', 'PS.jpg')
    $Ftpc = _FTPClose($Open)

i think i fixed it because it was in fact in the wrong directory

but it still is at 0 bytes :)

is the code right?

it looks ok to me. I dont think that the connection has to be close and reopened, try to have a 1 second sleep between each command and see what happeneds

[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#35 ·  Posted (edited)

it looks ok to me. I dont think that the connection has to be close and reopened, try to have a 1 second sleep between each command and see what happeneds

Case StringInStr ($con, "screenshot") > 0

DllCall("captdll.dll", "int", "CaptureScreen", "str", "PS.jpg", "int", 40)

$Open = _FTPOpen('MyFTP Control')

$Conn = _FTPConnect($Open, $server, $username, $pass)

_FTPDelFile($Conn, 'PS.jpg')

$Ftpc = _FTPClose($Open)

$Open = _FTPOpen('MyFTP Control')

$Conn = _FTPConnect($Open, $server, $username, $pass)

$Ftpp = _FtpPutFile($Conn, '?', '?')

$Ftpc = _FTPClose($Open)

what exactly goes in each '?', do we have to save the image in the include directory because thats where the ftp.au3 file is, or do we save it in the same folder as the script? (and if the file is in the same folder as the script, do we have to include the full path or just the filename?)

Edited by The Great 'Awesoma-Powa!'

Share this post


Link to post
Share on other sites

#36 ·  Posted (edited)

Case StringInStr ($con, "screenshot") > 0
    Sleep(1000)
    DllCall("captdll.dll", "int", "CaptureScreen", "str", @ScriptDir & "/TempPS.jpg", "int", 40)
    Sleep(1000)
    $Open = _FTPOpen('MyFTP Control')
    Sleep(1000)
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    Sleep(1000)
    _FTPDelFile($Conn, "/TempPS.jpg")
    Sleep(1000)
    $Ftpp = _FtpPutFile($Conn, @ScriptDir & '/TempPS.jpg', '/TempPS.jpg')
    Sleep(1000)
    $Ftpc = _FTPClose($Open)

i've made it so that the jpg saves in the same directory as the script (which it does)

and i've made it so that the file uploads the same way as the com.con file does

if $con <> "" Then
FileOpen ( "com.con", 2 )
$Open = _FTPOpen('MyFTP Control')
$Conn = _FTPConnect($Open, $server, $username, $pass)
_FTPDelFile($Conn, '/com.con')
$Ftpc = _FTPClose($Open)

$Open = _FTPOpen('MyFTP Control')
$Conn = _FTPConnect($Open, $server, $username, $pass)
$Ftpp = _FtpPutFile($Conn, @ScriptDir & '/com.con', '/com.con')
$Ftpc = _FTPClose($Open)
endif

and it still doesn't work! :)

i try the command through the site, and it takes a screencap and saves it in the same directory as the script. the file shows up on the ftp server but has 0 bytes! :\

Edited by The Great 'Awesoma-Powa!'

Share this post


Link to post
Share on other sites

#37 ·  Posted

Case StringInStr ($con, "screenshot") > 0

DllCall("captdll.dll", "int", "CaptureScreen", "str", "PS.jpg", "int", 40)

$Open = _FTPOpen('MyFTP Control')

$Conn = _FTPConnect($Open, $server, $username, $pass)

_FTPDelFile($Conn, 'PS.jpg')

$Ftpc = _FTPClose($Open)

$Open = _FTPOpen('MyFTP Control')

$Conn = _FTPConnect($Open, $server, $username, $pass)

$Ftpp = _FtpPutFile($Conn, '?', '?')

$Ftpc = _FTPClose($Open)

what exactly goes in each '?', do we have to save the image in the include directory because thats where the ftp.au3 file is, or do we save it in the same folder as the script? (and if the file is in the same folder as the script, do we have to include the full path or just the filename?)

It is the file that you need upload and the directory that it is going to


[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#38 ·  Posted

Case StringInStr ($con, "screenshot") > 0
    Sleep(1000)
    DllCall("captdll.dll", "int", "CaptureScreen", "str", @ScriptDir & "/TempPS.jpg", "int", 40)
    Sleep(1000)
    $Open = _FTPOpen('MyFTP Control')
    Sleep(1000)
    $Conn = _FTPConnect($Open, $server, $username, $pass)
    Sleep(1000)
    _FTPDelFile($Conn, "/TempPS.jpg")
    Sleep(1000)
    $Ftpp = _FtpPutFile($Conn, @ScriptDir & '/TempPS.jpg', '/TempPS.jpg')
    Sleep(1000)
    $Ftpc = _FTPClose($Open)

i've made it so that the jpg saves in the same directory as the script (which it does)

and i've made it so that the file uploads the same way as the com.con file does

if $con <> "" Then
FileOpen ( "com.con", 2 )
$Open = _FTPOpen('MyFTP Control')
$Conn = _FTPConnect($Open, $server, $username, $pass)
_FTPDelFile($Conn, '/com.con')
$Ftpc = _FTPClose($Open)

$Open = _FTPOpen('MyFTP Control')
$Conn = _FTPConnect($Open, $server, $username, $pass)
$Ftpp = _FtpPutFile($Conn, @ScriptDir & '/com.con', '/com.con')
$Ftpc = _FTPClose($Open)
endif

and it still doesn't work! :)

i try the command through the site, and it takes a screencap and saves it in the same directory as the script. the file shows up on the ftp server but has 0 bytes! :\

Humm, Thats odd, are you using a t35 account?

Oh, could the com.con be blank tho? maybe it is and when you look to see the file, the script has already cleared it? I bet thats what it is take out the clear command to see if it is that.


[center]AutoIT + Finger Print Reader/Scanner = COOL STUFF -> Check Out Topic![/center][center][font=Arial Black]Check out ConsultingJoe.com[/font][/center][center]My Scripts~~~~~~~~~~~~~~Web Protocol Managing - Simple WiFi Scanner - AutoTunes - Remote PC Control V2 - Audio SpectrascopePie Chart UDF - At&t's TTS - Custom Progress Bar - Windows Media Player Embed[/center]

Share this post


Link to post
Share on other sites

#39 ·  Posted

1. yes i'm using a t35 account

2. whenever i send a command the com.con deletes then reuploads

3. could the deletion and upload of the com.con file interfere with the deletion and the upload of the screenshot file? i think the paths for the file is right, so i'm still confused?

ps. can you add support for directory listing and file downloading from the remote comp. for this script?


Share this post


Link to post
Share on other sites

#40 ·  Posted

problem solved

it works, but apparently it was just my computer that had problems. sorry :)


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