Jump to content

dminion

Members
  • Posts

    14
  • Joined

  • Last visited

About dminion

  • Birthday 01/20/1977

dminion's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Yes I found a solution... I installed OpenSSL and used POP_ssl_V3.2.au3 and tested it using POP_ssl_V3.2_Example.au3. Seems to work pretty well. It does seem to be as you said in your other post though. It looks like it marks the messages as read so the next time you run the script, it doesn't show up in the list. Works fine for what I'm doing, making them invisible after I read them is exactly what I didn't know I needed... ;-) Thanks!
  2. 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.
  3. 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.
  4. Hey guys, sorry to reopen such and old thread but I'm having an issue with the POP_ssl_V3.2_Example.au3. When I run it, it will get a list of the emails in the inbox and display the first message. The next time I run it, the first message is no longer in the list. The 3rd time I run it, the 2nd message is gone and so on. Can anyone tell me why this is? Thanks!
  5. 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. #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!
  6. Hello all, I've been looking around for ways to get messages from a gmail account. I've found some posts that have some examples but have been unable to completely understand the scripts. I have downloaded an example script that will download and parse emails but it's looking for _POP.au3 which I can't find. Could someone please help me connect to a gmail account using IMAP so that I can download messages? I can use POP if I have to but IMAP would be preferable. Thanks in advance!
  7. INetSmtpMailCom is awesome and it works great until I put it in my script which calls it from within another function. The only issue that I have is that I don't get any error messages when it fails. Could someone please look at it for me? Thanks in advance! ; Setup email variables to send the merged email. Func MailerSetup() $SmtpServer = "smtp.gmail.com" ; address for the smtp-server to use - REQUIRED $FromName = $cust_name ; name from who the email was sent $FromAddress = $cust_email ; address from where the mail should come $ToAddress = "";$merge_email ; destination address of the email - REQUIRED $Subject = $cust_subject ; subject from the email - can be anything you want it to be $Body = $template_import ; the messagebody from the mail - can be left blank but then you get a blank mail $AttachFiles = "" ; the file you want to attach- leave blank if not needed $CcAddress = "" ; address for cc - leave blank if not needed ; address for bcc - leave blank if not needed If $cust_bcc = "y" Then $BccAddress = $cust_email Else $BccAddress = "" EndIf $Importance = "Normal" ; Send message priority: "High", "Normal", "Low" $Username = $cust_username ; username for the account used from where the mail gets sent - REQUIRED $Password = $cust_password ; password for the account used from where the mail gets sent - REQUIRED $IPPort = 465 ; port used for sending the mail. Use port 465 for GMAIL $ssl = 1 ; enables/disables secure socket layer sending - put to 1 if using https or GMAIL ;~ MsgBox(0, "Mail Settings", "$SmtpServer: |" & $SmtpServer & "|" & @CRLF & "$FromName: |" & $FromName & "|" & @CRLF & "$FromAddress: |" & $FromAddress & "|" & @CRLF & "$ToAddress: |" & $ToAddress & "|" & @CRLF & "$Subject: |" & $Subject & "|" & @CRLF & "$Body: |" & $Body & "|" & @CRLF & "$AttachFiles: |" & $AttachFiles & "|" & @CRLF & "$CcAddress: |" & $CcAddress & "|" & @CRLF & "$BccAddress: |" & $BccAddress & "|" & @CRLF & "$Importance: |" & $Importance & "|" & @CRLF & "$Username: |" & $Username & "|" & @CRLF & "$Password: |" & $Password & "|" & @CRLF & "$IPPort: |" & $IPPort & "|" & @CRLF & "$ssl: |" & $ssl & "|") ; Call the emailer $rc = _INetSmtpMailCom($SmtpServer, $FromName, $FromAddress, $ToAddress, $Subject, $Body, $AttachFiles, $CcAddress, $BccAddress, $Importance, $Username, $Password, $IPPort, $ssl) MsgBox(0, "Mailer Return", "Value: " & $rc & @CRLF & "@error: " & @error) If @error Then MsgBox(0, "Error sending message", "Error code: " & @error & @CRLF & "Description: " & $rc & @CRLF & @CRLF & "Subject: " & $Subject & @CRLF & "Message: " & $Body, 10) $error_pass = "Error sending message. Error code: " & @error & @CRLF & "Description: " & $rc & @CRLF & @CRLF & "Subject: " & $Subject & @CRLF & "Message: " & $Body Return $error_pass EndIf MsgBox(0, "", "Mail sent", 1) Return EndFunc ;==>MailerSetup Func _INetSmtpMailCom($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject = "", $as_Body = "", $s_AttachFiles = "", $s_CcAddress = "", $s_BccAddress = "", $s_Importance = "Normal", $s_Username = "", $s_Password = "", $IPPort = 25, $ssl = 0) Local $objEmail = ObjCreate("CDO.Message") $objEmail.From = '"' & $s_FromName & '" <' & $s_FromAddress & '>' $objEmail.To = $s_ToAddress Local $i_Error = 0 Local $i_Error_desciption = "" If $s_CcAddress <> "" Then $objEmail.Cc = $s_CcAddress If $s_BccAddress <> "" Then $objEmail.Bcc = $s_BccAddress $objEmail.Subject = $s_Subject If StringInStr($as_Body, "<") And StringInStr($as_Body, ">") Then $objEmail.HTMLBody = $as_Body Else $objEmail.Textbody = $as_Body & @CRLF EndIf If $s_AttachFiles <> "" Then Local $S_Files2Attach = StringSplit($s_AttachFiles, ";") For $x = 1 To $S_Files2Attach[0] $S_Files2Attach[$x] = _PathFull($S_Files2Attach[$x]) If FileExists($S_Files2Attach[$x]) Then $objEmail.AddAttachment($S_Files2Attach[$x]) Else ConsoleWrite('!> File not found to attach: ' & $S_Files2Attach[$x] & @LF) SetError(1) Return 0 EndIf Next EndIf $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = $s_SmtpServer If Number($IPPort) = 0 Then $IPPort = 25 $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = $IPPort ;Authenticated SMTP If $s_Username <> "" Then $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1 $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = $s_Username $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = $s_Password EndIf If $ssl Then $objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = True EndIf ;Update settings $objEmail.Configuration.Fields.Update ; Set Email Importance Switch $s_Importance Case "High" $objEmail.Fields.Item("urn:schemas:mailheader:Importance") = "High" Case "Normal" $objEmail.Fields.Item("urn:schemas:mailheader:Importance") = "Normal" Case "Low" $objEmail.Fields.Item("urn:schemas:mailheader:Importance") = "Low" EndSwitch $objEmail.Fields.Update ; Sent the Message $objEmail.Send If @error Then SetError(2) Return $oMyRet[1] EndIf $objEmail = "" EndFunc ;==>_INetSmtpMailCom ; Com Error Handler for _INetSmtpMailCom Func MyErrFunc() $HexNumber = Hex($oMyError.number, 8) $oMyRet[0] = $HexNumber $oMyRet[1] = StringStripWS($oMyError.description, 3) ConsoleWrite("### COM Error ! Number: " & $HexNumber & " ScriptLine: " & $oMyError.scriptline & " Description:" & $oMyRet[1] & @LF) SetError(1); something to check for when this function returns Return EndFunc ;==>MyErrFunc
  8. I'm looking for some examples for GuiCtrlCreateDummy usage. Can someone tell me where I can find examples? Are they just in the help file or are there more? thanx, dminion
  9. Hi, I have a question. I'm using a 3 button GUI that is popped up in the middle of a loop if an error occurs. The first time the GUI is made visible, all of the buttons work fine but if the loop is then restarted by the GUI, none of the buttons function at all the next time it comes up... does anyone have an idea of what would cause something like that? I have attached my script. This is my first GUI so I'm kinda new at this... thanks! dminion M1_DVD_02_15_06_0_Local.au3
  10. I'm not sure I follow... how exactly will this lock the drive tray? It looks like it just opens and closes drive trays... Thanks, dminion
  11. Does anyone know of a way to lock and unlock the cdrom drive tray using auto it? I've looked around and have only found ways to do it in VB. Can someone please help? Thanks, dminion
  12. Cool... I'll give those a shot. Do you think that would cause a drive to completely disappear from the system though? Like the drive was even gone from the device manager... Thanks, dminion
  13. Do you mean the FileClose function for the error message? FileClose($copy_log_open)Or a new FileClose() Function? What exactly would that do? Thanks, dminion
  14. Hi, This is the first time I've posted here and I'm having an issue with a script I'm writing. The purpose of the script is to identify and copy dvd's based on ini files in a program. everything seems to work fine unless there's a crc error or something during the copy process. If I cancel out of the script, the dvd drives vanish and don't reappear unless I hard boot the machine... I'm at a loss... can someone please help? Thanks, dminionDVD_Copy_01_11_06_0.au3
×
×
  • Create New...