Sample code for 30+ languages & platforms
Go

Example: MailMan.FetchAll method

Demonstrates how to call the FetchAll method.

Chilkat Go Downloads

Go
    success := false

    success = false
    mailman := chilkat.NewMailMan()

    // Setup mailman with POP3 server and login settings...
    // ...
    // ...

    bundle := chilkat.NewEmailBundle()
    keepOnServer := true
    headersOnly := false
    // numBodyLines only applies if downloading headers-only.
    numBodyLines := 0

    success = mailman.FetchAll(keepOnServer,headersOnly,numBodyLines,bundle)
    if success == false {
        fmt.Println(mailman.LastErrorText())
        mailman.DisposeMailMan()
        bundle.DisposeEmailBundle()
        return
    }

    // ...
    // ...

    mailman.DisposeMailMan()
    bundle.DisposeEmailBundle()