Sign in to follow this  
Followers 0
hipitarius

TCPConnect

4 posts in this topic

I have looked all over the forum and help file and have found nothing about transfering anything other then simple text via the TCP with autoit. Is this cause im missing it or it isn't possible. I just want to make a little server program that maybe 10 people or so could connect to and download files from my computer.

Thanks

Share this post


Link to post
Share on other sites



well i didn't think this was a totally rediculous question but apparently i was wrong, come on guys im looking for a one word answer, not a script. Is autoit as of today capable of transfering files (aka an mpeg) via sockets or any other method.

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

well i didn't think this was a totally rediculous question but apparently i was wrong, come on guys im looking for a one word answer, not a script.  Is autoit as of today capable of transfering files (aka an mpeg) via sockets or any other method.

I believe it's up to you to handle what's transferred and how it's handled. If you make arrangements with the receiver so it knows you're sending binary data and tell it what to do with that (save it), then you just start streaming the bits across, that should work.

Think about the FTP protocol. One end says, "the file I want is binary" and the server responds with "okay". Then one says "give me file myfile.exe" and the server says "okay, here it comes". The other end expects some binary data to start streaming and the server knows that, so it streams the data, sending a ctrl-z or whatever at the end to let the client know that it's at the end of the file. The client stops expecting data, does something with what it's received and performs the next operation (get the next file). The sockets are just used to transfer the data. The FTP program has to know what to do with the data.

Edited by c0deWorm

My UDFs: ExitCodes

Share this post


Link to post
Share on other sites

AutoIt natively only supports textual data (NULL character issues for the most part), however, thanks to Larry's ingenuity, there are several UDF functions that can read and manipulate binary data in AutoIt, in essense allowing for binary data transfer over TCP (and UDP).

Look for _APIFileRead() functions in the forum


Writing AutoIt scripts since
_DateAdd("d", -2, _NowCalcDate())

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