Gary Reimer Posted March 9, 2016 Posted March 9, 2016 Hi I need to get a count of email in the sent folder, that were sent today. I've been successful with Inbox but not Sent. When I try EmailGetMessageCount ( "mailbox=Sent") I get ERROR. Is it possible to get a mail count from Sent?
ryan360Works Posted March 11, 2016 Posted March 11, 2016 Hello, More than likely the error is that "sent" does not exist. You can check this by calling EmailLastError after you get ERROR. Call the function EmailListMailboxes. Be sure that you list all the mailboxes. You can do so by calling EmailListMailboxes("";"true") . This will list all mailboxes for the account.
Gary Reimer Posted March 14, 2016 Author Posted March 14, 2016 Thanks Ryan for your reply. I used your advice but it still didn't work. Here's what happened. EmailListMailBoxes showed that INBOX and Sent Items among others existed. But when I do: EmailGetMessageCount ( "mailbox = Sent Items") or EmailGetMessageCount ( "mailbox = INBOX") I get an error that says the mailbox does not exist. If I do EmailGetMessageCount I get the mail count for INBOX. Any further suggestion?
Caleb360Works Posted March 14, 2016 Posted March 14, 2016 Try using EmailListMailboxes to figure out the valid name for your sent folder and then pass that into EmailGetMessageCount.
Gary Reimer Posted March 14, 2016 Author Posted March 14, 2016 I already did that. In my previous message I said EmailListMailBoxes showed that INBOX and Sent Items among others exist. But when I do:EmailGetMessageCount ( "mailbox = Sent Items") orEmailGetMessageCount ( "mailbox = INBOX") I get an error that says the mailbox does not exist.
Caleb360Works Posted March 14, 2016 Posted March 14, 2016 My apologies, I did not notice that. However, are you doing: EmailGetMessageCount ( "mailbox = INBOX") or EmailGetMessageCount ( "mailbox=INBOX") Try doing it without the spaces.
Gary Reimer Posted March 14, 2016 Author Posted March 14, 2016 Wow. I never would have thought of that. Thank you so much. It now works. From now on, no spaces around = anywhere in the email plugin. Thanks Gary
Recommended Posts
This topic is 3513 days old. Please don't post here. Open a new topic instead.
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