theguy0000 Posted October 25, 2007 Share Posted October 25, 2007 (edited) Well, I searched around, then I asked around, but nobody seemed to have ever made pop3 functions for AutoIt. And ta-da, pop3.au3It's just a starter, of course. Right now all it can do is connect, log in, check number of messages, size of mailbox, and retrieve messages (which I'm not sure is completely perfect). I still need to make it able to delete messages. Also, I have no idea how to make it support connections that require SSL (like gmail). If anyone knows that, I'd be glad to hear it...Note: You must TcpStartup () bvefore using any pop3 functions and also TcpShutdown at the end of the script.Anyway, here is a list of the functions:expandcollapse popup;=============================================================================== ; ; Description: Connects and logs in to the pop3 server ; Parameter(s): $sServer - IP address of the server to connect to ; $iPort - port to connect on - usually 110 ; $sUser - Username to use to log in ; $sPass - Password to use to log in ; Requirement(s): TcpStartup () ; Return Value(s): On Success - Difference between the 2 dates ; On Failure - False and Set @Error to: ; 1 - Timed out while waiting for server to respond ; 2 - Server gave error response ; 3 - Could not connect to server ; Author(s): Matt Roth (theguy0000) <theguy0000 at gmail dot com> ; ;=============================================================================== ;=============================================================================== ; ; Description: Counts the number of messages in the mailbox ; Parameter(s): $sock - Socket previously returned by _pop3start () ; Requirement(s): None. ; Return Value(s): On Success - Number of messages in the mailbox ; On Failure - False and Set @Error to: ; 1 - Timed out while waiting for server to respond ; 2 - Server gave invalid response ; Author(s): Matt Roth (theguy0000) <theguy0000 at gmail dot com> ; ;=============================================================================== ;=============================================================================== ; ; Description: Finds the total size of a mailbox. ; Parameter(s): $sock - Socket previously returned by _pop3start () ; Requirement(s): None. ; Return Value(s): On Success - Size of the mailbox in octets (bytes). ; 1 - Timed out while waiting for server to respond ; 2 - Server gave invalid response ; Author(s): Matt Roth (theguy0000) <theguy0000 at gmail dot com> ; ;=============================================================================== ;=============================================================================== ; ; Description: Retrieves a message from the mailbox. ; Parameter(s): $sock - Socket previously returned by _pop3start () ; $iNum - the number of the message to retrieve. ; Requirement(s): None. ; Return Value(s): On Success - An Array containing info about the message: ; [0] = Sender ; [1] = Subject ; [2] = the message itself ; On Failure - False and Set @Error to: ; 1 - Timed out while waiting for server to respond ; 2 - Server gave error response ; 3 - Couldn't find some info in the message (eg boundary, sender, subject) ; Author(s): Matt Roth (theguy0000) <theguy0000 at gmail dot com> ; ;===============================================================================more to comedownload here: pop3.au3 Edited October 25, 2007 by theguy0000 The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted October 25, 2007 Moderators Share Posted October 25, 2007 Now I've seen it all An example thread, no exe only, no source and exe, no source... 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. Link to comment Share on other sites More sharing options...
theguy0000 Posted October 25, 2007 Author Share Posted October 25, 2007 i probably should have put this in a more obvious place, but the download is in the first sentence of the post... The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Link to comment Share on other sites More sharing options...
tAKTelapis Posted October 26, 2007 Share Posted October 26, 2007 Now I've seen it all An example thread, no exe only, no source and exe, no source... The Code box is only listing functions, The .au3 file contains actual code. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted October 26, 2007 Moderators Share Posted October 26, 2007 i probably should have put this in a more obvious place, but the download is in the first sentence of the post...Definately not your fault then, I blame it on the 12 pack I had before I read the post, and the 6 pack I had after words trying to decipher what you just said , but alas, I understand and can take a look 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. Link to comment Share on other sites More sharing options...
Apzo Posted October 26, 2007 Share Posted October 26, 2007 Well, I searched around, then I asked around, but nobody seemed to have ever made pop3 functions for AutoIt. And ta-da,Sorry I haven't seen your call !All pop3 funcs are here :http://www.autoitscript.com/forum/index.php?showtopic=22838It's old, but still works.Have fun Apzo. All the pop3 functions.Rsync your files on your USB key (or anywhere else) Link to comment Share on other sites More sharing options...
Lord Freshy Posted January 21, 2008 Share Posted January 21, 2008 (edited) Sorry I haven't seen your call !All pop3 funcs are here :http://www.autoitscript.com/forum/index.php?showtopic=22838It's old, but still works.Have fun Apzo.i'm trying to put this to work for ages..but still, i can't :\not the ones from this post neither the ones from the post u referred... i'm trying to create a function that reads the first line of the first email and writes it to a .txt file in my local hard drive. :\ any ideas? It's the only script that I need to complete my first BIG project... thanks in advance Edited January 21, 2008 by Lord Freshy Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now