Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Hi there

I have an issue where it will not get all the mail from the exchange mailbox (using imap). I have tried a variety of things including deleting all the messages for that mailbox before trying to fetch (and resetting the serial) because initially if I did this it seemed to get all the mail instead of just one but now each time I only get one message regardless for this inbox/account. There are 4 emails in the inbox and I am just getting the latest one not all 4 which is my desired outcome.

The issue seems to be at the line of code where it says... Exit Loop If [not EmailGetNextMessage] - as it appears to be exiting before it has been through all the messages in the xml file? I have two accounts set up and the other account is also not clearing all the messages (56 out of 170) - again I have cleared out all "message" records so it should not think that any already exist?

I am not sure why it keeps exiting. I am using version 2.17 of the mail plugin and running it both on the server and on client (same result from script on both). I have tried changing the exit loop to met another condition instead but still no luck. The EmailGetMessageCount( 1 ) seems to be returning a correct number of messages but the exit loop is happening before it has created all the messages. I have attached the script. I want to get all messages in the inbox each time as during initial testing if we deleted mail from the exchange server it was not showing as deleted in filemaker - and we need what is in filemaker to reflect exactly what is in the exchange mailbox.

Is it something simple that I just need to alter in the script so it does not exit until it has created all messages?

Kind regards

Katy

 

 

 

fectch mail script.pdf

  • Author

Changed the Exit Loop to be $EmaiNextMessage ≠ 1

But then I was only getting every second one as I caused my own headaches by adding...

If [ (not EmailGetNextMessage) and ($count = 2) and ($messageCountCustom > 0) ]
Beep
End If

...when I was trying to troubleshoot and of course then it was calling the EmailGetNextMessage function twice so I was only getting every second one!

Changing the Exit Loop condition and disabling the test I had added has meant I have now been able to get the full set.

Happy things are working now as expected. Good lesson on being careful about adding in a test like that and the implications.

 

Edited by kiwikaty
Worked it out!

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.