When you use Skype for Business (or Lync), you can save your conversations in your Outlook data file. To do this, Lync needs to access your .ost file. Under normal conditions, this process works very well and goes unnoticed.
If, when Skype for Business is running, you are receiving errors stating that the folder cannot be open, or you don't have permission to access the file when you try to open appointments or email messages, first check your Skype for Business options, then the compatibility mode settings for both Outlook and Skype for Business.
The set of folders cannot be opened. The file C:\Users\username\local settings\application data\microsoft\outlook\outlook.ost accessed. Close any application that is using this file, and then try again. You might need to restart your computer
You may see this error message when opening the Calendar or Contacts folder:
Cannot display the folder. File access is denied. You do not have the permission required to access the file C:\Users\username\local settings\application data\microsoft\outlook\outlook.ost.
Or this message when attempting to open a message:
Cannot open this item. File access is denied. You do not have the permission required to access the file C:\Users\username\local settings\application data\microsoft\outlook\outlook.ost.
If you exit Skype for Business, the error goes away and you can open the message or calendar without a problem. When you restart Skype for Business, the problem eventually returns. If you wait a bit (maybe 5-10 minutes), the problem may go away on its own.
Solutions
There are three possible causes/solutions for this behavior:
- Skype for Business (Lync) is connected to Outlook and accessing the .ost file.
- The Lync or Skype shortcut or application is configured to run in Compatibility mode.
- You may receive this error if you have Lync or Skype set to run as administrator.
Skype is accessing the OST file
Skype for Business accesses your mailbox to sync meetings and contacts, and to save your conversation history. This is often responsible for the 'folders cannot be opened' error message.
The set of folders cannot be opened. The file C:\Users\username\local settings\application data\microsoft\outlook\outlook.ost accessed. Close any application that is using this file, and then try again. You might need to restart your computer
To fix, try unticking the option to save conversations and conversation logs in the Conversation folder in Outlook. Unticking the other options under Exchange and Outlook integration may help as well, but the Conversation options are usually the ones responsible for the file access denied error.
Change Compatibility Settings
There is no reason to use compatibility mode with any Office application, including in older unsupported Office applications.
Check Compatibility Mode Settings
- To disable Compatibility mode or confirm its not enabled, right click on the Lync or Skype shortcut, then select Properties.
- Click the Compatibility tab in the Properties dialog and uncheck the Compatibility mode box that says "Run this program in Compatibility Mode".
Run as Administrator
In most cases, it won't matter if you use the run as administrator option, but it also should not be enabled permanently (for most users). We recommend disabling run as administrator (if enabled).
We have a video tutorial at How to Disable Compatibility Mode in Outlook. While this shows how to disable it in Outlook, the process is similar for other applications.
Set the outlook file to run as admin this seemed to fix the problem on our end
Also Verify that the version of Lync is from the same office version (package) you're running for outlook, otherwise this conflict might appear too.
- if you turn off caching mode for outlook it will run slower when on Office 365
- if you turn off use outlook file in lync no more data will be in sync in either direction. keep that in mind.
I checked the Run key in the registry under HKCU/Software/Microsoft/Windows/CurrentVersion/Run and found that it was still pointing to the Office 15 (2013) version of Lync after I had installed Office 16 (2016). Changed the path to C:\Program Files\Microsoft Office\root\Office16\lync.exe in this registry value.
OK Thanks Diane, also I found turning off cached exchange mode on outlook stops the .ost file in use errors as well if anyone needs it still fix this.
Yeah, that will do it too, although it came make Outlook seem like a slug. It's generally better to stop skype from using it.
Try this ... go into Lync, open 'Tools' then 'Options' then 'Personal' then set "Personal information Manager" to 'None' this should stop issues with opening lync and outlook and possible .ost issues.
I am looking for a way to change the Lync data file to use a separate ost file but haven't found a solution yet if anyone has one let me know. Thanks. In mean time will keep looking and play with the registry to see if I can find where to change the path in there.
You can't change it to use a different data file.
The problem we have is that users will sporadically stop receiving e-mail in Outlook. We traced this to the UcMapi.exe process locking the OST. This is still happening in our environment but not sure if it's only affecting Outlook 2010 users or 2010 and 2013 (we have a mixed install-base).
Don't show my photos to public or friends
Lync isn't showing your contact photos? Which version of Lync are you using?
Ok... I am not running in compatibility mode, run as administrator is not checked. However, When I reboot my computer and log in, Lync Starts, then Outlook tries to start. The only way I can get this to work is to quit Lync from the task manager, start outlook, then restart Lync. Otherwise I keep getting messages that my ost file is locked.
There are options in Lync that access outlook data - they turning them off. Depending on your version of Lync, you might have options to update presence based on Free/Busy, store IM conversation history and call logs in outlook, sync Lync and exchange contacts. Those options all need to access the ost.
You don't need to run in compatibility mode to minimize it to the system tray. That option is set in Lync 2010 under the Tools > Options > General:
"Minimize to the notification area instead of the task bar"
As for Outlook 2010, I'm not sure what it is, but the annoying process UcMapi.exe from lync is constantly hosing up Outook profiles and corrupting the ost files.
It's the most annoying thing in the world for a business.