dminion Posted February 16, 2010 Posted February 16, 2010 (edited) Hey everyone, I'm having an issue with this script. It will look at the email messages in the inbox once and after that it will not see them again the next time I run it. It's like it's removing them from the inbox but when I log into the account, they're still there. expandcollapse popup#include <Array.au3> #include "POP_ssl_V3.2.au3" Global $cust_username = "user_removed", $cust_password = "pass_removed" ;~ Opt("OnExitFunc", "endscript") Opt("SendKeyDelay", 0) Opt("TrayIconDebug", 1) ;kill previous run While ProcessExists("openssl.exe") ProcessClose("cmd.exe") ProcessClose("openssl.exe") WEnd ;###FILL IN THIS INFO### $User = $cust_username $Pass = $cust_password ;set server info $SSL_Exe_loc = "C:\OpenSSL\bin\openssl.exe" $POP_Server = "pop.gmail.com" $POP_Port = "995" $error = "" $msg = _POP_Connect($POP_Server, $POP_Port, $SSL_Exe_loc, True) ;MsgBox(0, $msg & " - " & @error, $_POP_Log) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_Login($User, $Pass) ;MsgBox(0, $msg & " - " & @error, $_POP_Log) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_GetStats() MsgBox(0, "", $msg) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_GetList() _ArrayDisplay($msg) $error &= $msg & " - " & @error & @CRLF $msg = _POP_GetMessage(1) _ArrayDisplay($msg) $error &= $msg & " - " & @error & @CRLF $msg = _POP_Disconnect() $error &= $msg & " - " & @error & @CRLF EndReport($error) Func EndReport($error) MsgBox(0, "", $error) Exit EndFunc ;==>EndReport Anyone have any ideas? Thanks! Edited February 16, 2010 by dminion
dminion Posted February 16, 2010 Author Posted February 16, 2010 Hey everyone, I'm having an issue with this script. It will look at the email messages in the inbox once and after that it will not see them again the next time I run it. It's like it's removing them from the inbox but when I log into the account, they're still there. expandcollapse popup#include <Array.au3> #include "POP_ssl_V3.2.au3" Global $cust_username = "user_removed", $cust_password = "pass_removed" ;~ Opt("OnExitFunc", "endscript") Opt("SendKeyDelay", 0) Opt("TrayIconDebug", 1) ;kill previous run While ProcessExists("openssl.exe") ProcessClose("cmd.exe") ProcessClose("openssl.exe") WEnd ;###FILL IN THIS INFO### $User = $cust_username $Pass = $cust_password ;set server info $SSL_Exe_loc = "C:\OpenSSL\bin\openssl.exe" $POP_Server = "pop.gmail.com" $POP_Port = "995" $error = "" $msg = _POP_Connect($POP_Server, $POP_Port, $SSL_Exe_loc, True) ;MsgBox(0, $msg & " - " & @error, $_POP_Log) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_Login($User, $Pass) ;MsgBox(0, $msg & " - " & @error, $_POP_Log) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_GetStats() MsgBox(0, "", $msg) $error &= $msg & " - " & @error & @CRLF If $msg == False Then EndReport($error) $msg = _POP_GetList() _ArrayDisplay($msg) $error &= $msg & " - " & @error & @CRLF $msg = _POP_GetMessage(1) _ArrayDisplay($msg) $error &= $msg & " - " & @error & @CRLF $msg = _POP_Disconnect() $error &= $msg & " - " & @error & @CRLF EndReport($error) Func EndReport($error) MsgBox(0, "", $error) Exit EndFunc ;==>EndReport Anyone have any ideas? Thanks! Here's an update. If I go into gmail and set the pop settings to "Enable POP for all mail (even mail that's already been downloaded)" they all come back. But this is what I had originally set it to.
DJKMan Posted February 16, 2010 Posted February 16, 2010 Using this method you are able to download the new emails and then mark them as read so that the next time you run this script the read email messages will not show up again, correct?
dminion Posted February 16, 2010 Author Posted February 16, 2010 Using this method you are able to download the new emails and then mark them as read so that the next time you run this script the read email messages will not show up again, correct?Thanks for your reply.I'm not sure if that's what it's supposed to do or not but when I log into gmail, it still shows them as unread.
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