How to Fix Outlook VBA Error 80070057 When Saving a MailItem
Question details
The user needs to resolve a VBA error that prevents an email macro from saving a MailItem to the Drafts folder.

- Product
- Microsoft Outlook
- Device & OS
- not provided
- Scenario
- Running an Outlook VBA macro to generate and save a draft email after adding a secondary email account to the Outlook profile.
- Observed behavior
- The VBA script throws runtime error -2147024809 (80070057) on the MailItem.Save method because the destination folder, account store, sender, or recipient objects become invalid or ambiguous when multiple accounts are present.
Before modifying your VBA code, ensure you have backed up your current Outlook macros and verify the exact email addresses associated with the multiple accounts in your Outlook profile.
Explicitly Resolve the Target Account and Drafts Folder
Update your VBA script to target the correct Outlook store and explicitly assign the email to that specific account's Drafts folder to prevent ambiguity.
When a secondary account is added to Outlook, the default application context may no longer know which account's Drafts folder to use. Explicitly defining the Store and mapping the MailItem to it resolves the 80070057 error.
Press ALT + F11 in Outlook to open the Visual Basic for Applications editor and locate the macro generating the error.
Modify your code to loop through 'Application.Session.Stores' or 'Application.Session.Accounts' to find the specific account you want to send from.
Set the 'MailItem.SendUsingAccount' property to the matched account object to ensure the sender is valid.
Use 'Store.GetDefaultFolder(olFolderDrafts)' to get the correct Drafts folder for that specific account.
Instead of a generic '.Save', use 'MailItem.Move(targetDraftsFolder)' or set the item's saved location explicitly before calling the Save method.

Validate All Recipient Address Entries
Ensure that all recipients added to the MailItem resolve to a valid AddressEntry before calling the Save method.
Upgrade Your Productivity with WPS Office
If you are tired of complex VBA script errors and troubleshooting multi-account issues in Microsoft Office, consider switching to WPS Office. It provides a lightweight, highly compatible alternative for your daily document workflows without the steep technical learning curve.
- 1. Download the Installer: Visit the official WPS Office website and download the free installation package.
- 2. Install WPS Office: Run the installer and follow the on-screen prompts to set up the software on your computer.
- 3. Open Your Documents: Launch WPS Office to easily open, edit, and save your existing Microsoft Office files.

Frequently Asked Questions
Why does MailItem.Save work with one account but fail with multiple?
When a secondary account is added, Outlook may lose context of the default data store. You must explicitly define which account's Drafts folder the MailItem belongs to so Outlook knows exactly where to save the file.
Does the MailItem.Display method bypass error 80070057?
Calling the Display method allows the email to render on screen and be sent manually, but it does not fix the underlying folder or recipient resolution issue that prevents programmatic saves to the Drafts folder.
How do I verify if a recipient object is valid in Outlook VBA?
You can use the Recipient.Resolve method in your VBA script. If the method returns True, the recipient is valid and properly linked to a recognized AddressEntry in your address book.




