Hi all!
I need to show a list of all flagged emails, which works for some users but not for others.
I have tried using both GetEmailsV2 & V3. For myself it works brilliantly, but not for a colleague using the app; he gets no email at all even if he does indeed have flagged emails.
I have set a data table's Items-property to:
Office365Outlook.GetEmailsV3({fetchOnlyFlagged:true}).value
As I wrote, it works very well for me but not for a colleague - why and what can I do to remedy it?
Thanks in advance!
I think we found the "problem": when getting flagged messages it retrieves unread messages only! To get flagged messages that also have been read, you have to specify the fetchOnlyUnread:false as well.
It would be a great idea to update the documentation with this information!!!!!
The whole point of the question is: it does not work! I get zero (0) messages back for some users, even if they have flagged messages.
Since it works for me, is there some sort of setting in the mail box they have done that stops the function to work properly? I've read the documentation several times, and there is nothing in it about cases like this.
Hi @BitLord69 ,
The Office365Outlook.GetEmailsV3() function currently could only retrieve 25 emails at most once time. In other words, if there are 50 Flagged emails in your Mailbox, this function could only retrieve first 25 emails (You could specify search query within this function to get the latest 25 Flagged emails).
If you would like this feature to be improved in PowerApps, please submit an idea to PowerApps Ideas Forum:
https://powerusers.microsoft.com/t5/Power-Apps-Ideas/idb-p/PowerAppsIdeas
Best regards,
I want to get *only* flagged messages, so what about limitations for that?
Hi @BitLord69 ,
Currently, there are some known limits with Office 365 Outlook connector, if you want to search all messages within your mailbox, and filter these emails matching the specific criteria, I afraid that the Office 365 Outlook connector could not achieve your needs.
Best regards,
Hi again,
I tried this, as per your suggestion:
Office365Outlook.GetEmailsV3({fetchOnlyFlagged:true, top:25, searchQuery:"$orderby=received desc"}).value
but my colleague says it still does't work for him. He probably has more than 25 flagged messges in his inbox, but shouldn't your suggestion work anyway?
We will try with two beta testers tomorrow, so will see how it works for them.
Thanks!
Hi @BitLord69 ,
Currently, there is an known limit with the Office365Outlook.GetEmailsV3() function -- It could only return 25 emails at most once time.
If you specify a number value more than 25 for the top attribute, the following error message would show up:
How many Flagged emails existed in your end user's mailbox? More than 25? If there are more than 25 Flagged emails existed in your end user's mail box, I afraid that there is no way to achieve your needs.
The "fetchOnlyFlagged" attribute is not applied to the "first 250 limits", it could only retrieve 25 emails at most once time. If you want to retrieve the latest 25 Flagged emails, please modify your formula as below:
Office365Outlook.GetEmailsV3({fetchOnlyFlagged:true, top:25, searchQuery:"$orderby=received desc"}).value
Best regards,
Hi Kris!
Thanks for your reply.
The other user have the same mail box, he has signed in and accepted the different connectors when he started to use the app. There is no error message at all when trying to see flagged emails.
Furthermore, in the app one can also choose to look at calendar events, not yet completed tasks and planner plans/buckets/tasks. All of these things my colleague can access and see; it's only flagged mail that won't dance.
In the article you reference, they write:
This operation gets emails from a folder via graph apis. Please note that filtering related to these fields: To, Cc, To Or Cc, From, Importance, Fetch Only With Attachments, Subject Filter, is performed using first 250 items in a given mail folder. To avoid that limitation you can use 'Search Query' field.
Could that be the reason? What does the first 250 items mean? Does it sort the mails by date, ascending or descending? My colleague certainly has more than 250 mails in his inbox, so maybe that is why.
They recommend to use the seach query, but as I understand it, you cannot get flagged messages that way.
Looking forward to hear more from you.
Jan-Erik Karlsson
Hi @BitLord69 ,
Are there some error messages occurred when your end users run the Office365Outlook.GetEmailsV3() function on their side?
Do these end users own same Office 365 license as you for accessing Outlook connector from canvas app?
I have made a test on my side, and don't have the issue that you mentioned. Firstly, please make sure your end users have enabled REST API feature for their Office 365 Mailbox.
There are some known limits with Office 365 Outlook connector in PowerApps, please check the following article:
https://docs.microsoft.com/en-us/connectors/office365/#known-issues-and-limitations
Also please make sure your end users have owned proper Office 365 license to use Office 365 Outlook connector in canvas app (same with you at least).
In addition, also please make sure they have owned proper PowerApps license for accessing PowerApps canvas app you shared to them.
Note: When your end user to access your shared canvas app, he would be prompted to provide their own credential to create connection to Office 365 Outlook connected used in your shared app. Please make sure your colleague provide his own proper credential to create a connection to the Office 365 Outlook connector used in your app
Best regards,
MS.Ragavendar
27
mmbr1606
14
Super User 2025 Season 1
EE-04041031-0
11