Learn R Programming

mRpostman (version 0.3.1)

select_mailbox: Mailbox Selection

Description

Select a mailbox on the server for issuing further commands.

Usage

select_mailbox(imapconf, mbox, retries = 2)

Arguments

imapconf

A object of class imapconf generated with configure_imap.

mbox

A string containing the name of an existing mailbox on the server.

retries

Number of attempts to connect and execute the command. Default is 2.

Value

The (invisible) imaconf object with the selected mailbox added to it.

See Also

Other mailbox commands: examine_mailbox, list_mailboxes, list_server_capabilities, rename_mailbox

Examples

Run this code
# NOT RUN {
# configure IMAP
library(mRpostman)
imapconf <- configureIMAP(url="imaps://imap.gmail.com",
                          username="your_gmail_user",
                          password=rstudioapi::askForPassword()
                         )

# Select INBOX
imapconf %>%
  select_mailbox(mbox = "INBOX")

# }

Run the code above in your browser using DataLab