Got a weird issue with one of my AppleScripts. I’m using AppleScript to get data out of Outlook. One customer gets the error message “error: -1708, Microsoft Outlook got an error: mail folder id 115 doesnt understand the ‘save’ message” when executing the script. The script has been used successfully for years. Google hasn’t really helped.
with timeout of 10000 seconds
set rand1 to (round (random number from 100 to 999)) as string
set rand2 to (round (random number from 100 to 999)) as string
set rand3 to (round (random number from 100 to 999)) as string
set rand4 to (round (random number from 100 to 999)) as string
set randomString to rand1 & "-" & rand2 & "-" & rand3 & "-" & rand4
tell application "Microsoft Outlook.app"
set theFolder to mail folder "Inbox" of exchange account "xyz"
set storageFolder to path to temporary items as string
set storageFolder to storageFolder & "Outlook Export " & randomString
try
save theFolder in storageFolder
on error errMsg number errNr
return "error: " & errNr & ", " & errMsg as string
end try
return storageFolder
end tell
end timeout
We tried several different mailboxes. Also, we tried a different location instead of the temporary folder. Before calculating the mailbox path another script gets all mailboxes and accounts. Therefore I’m sure that the account exists.
It’s also not the problem with the VM running Outlook. In this case ALL scripts fail.
All my scripts are generated dynamically with NSAppleScriptMBS. Xojo 2014r3, Mac OS 10.10.x, Outlook 2011.