Metadata not saving when Office Document is password protected
This is a known issue. The metadata is actually stored within the document and gets read into SharePoint when being saved. Unfortunately, since the document is password protected, SharePoint cannot read the metadata values and therefore you lose them. More precise, if you open the document for example in Excel you will see in your Document Information Panel (DIP) that the metadata is stored (in the document), but you won’t see the metadata in SharePoint.
You have 2 different options to password protect an Office document, you can enter a “password to open” and/or a “password to modify“. The problem only occurs when you enter a “password to open”. If you use “password to modify” SharePoint will be able to read the metadata from the document.