| Author |  | 
      
        | Vladimir Guest Group
 
  
 
 Joined: 10 November 2003
 Online Status: Online
 Posts: 262
 | 
          When I run the following code:
           | Posted: 26 April 2006 at 1:03pm | IP Logged |   |  
           | 
 |  
 Set Mailer = CreateObject("MailBee.POP3")
 Mailer.LicenseKey = "MyKey"
 Mailer.Connect HOST, PORT, USERNAME, PASSWORD
 Set Msgs = Mailer.RetrieveHeaders
 
 TOTAL =  Msgs.Count
 
 It brokes on the last line (Msgs.Count)
 
 Microsoft VBScript runtime error '800a01a8'
 Object required
 
 When I remove the line it goes fine with no errors, so it creates the MailBee.POP3 with no problems. Seem like the Mailer.RetrieveHeaders fails for some reason.
 
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | Alex AfterLogic Support
 
  
  
 Joined: 19 November 2003
 Online Status: Offline
 Posts: 2207
 | 
          To programmatically check for errors, use .IsError or .ErrCode properties of POP3 object. You can find samples in C:\Program Files\MailBee\Samples folder (or wherever you installed MailBee Objects).
           | Posted: 26 April 2006 at 1:12pm | IP Logged |   |  
           | 
 |  
 To quickly check what exactly is going wrong, you can enable logging into a file and then examine the log file:
 
 
 
| Code: 
 
    
    | 
      
       | Set POP3 = CreateObject("MailBee.POP3")
 POP3.EnableLogging = True
 POP3.LogFilePath = "C:\log.txt"
 ...
 
 |  |  |  
 Make sure your application has appropriate permissions to write into the specified location.
 
 Regards,
 Alex
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | Vladimir Guest Group
 
  
 
 Joined: 10 November 2003
 Online Status: Online
 Posts: 262
 | 
          Thanks, figured it out :)
           | Posted: 26 April 2006 at 1:44pm | IP Logged |   |  
           | 
 |  | 
       
        | Back to Top |     | 
       
       
        |  |