NetOfficeFw / NetOffice

🌌 Create add-ins and automation code for Microsoft Office applications.
MIT License
700 stars 145 forks source link

PowerPoint.ReadOnlyRecommended missing #411

Closed robertmuehsig closed 5 months ago

robertmuehsig commented 7 months ago

This property is missing in NetOffice: Presentation.ReadOnlyRecommended

https://learn.microsoft.com/en-us/office/vba/api/powerpoint.presentation.readonlyrecommended

It seems this thing came with Office 2019 (e.g. see the OpenXml Remarks.

As a workaround I used this:

 try
 {
     // OfficeInstance == Presentation
     bool isReadOnlyRecommended = OfficeInstance.Property<bool>("ReadOnlyRecommended");
     if (isReadOnlyRecommended)
     {
         return true;
     }
 }
 catch (PropertyGetCOMException)
 {
     // ignore, might happen on pre Office 2019 versions
 }

If you wonder where to enable this - here:

image

jozefizso commented 5 months ago

Hi @robertmuehsig , well, this took unnecessary long time to release, I am sorry for that.

Mostly because I did not have availabel new signing certificate and to get the private preview of the Azure Trusted Signing service it took 6 months from requesting it in January.

jozefizso commented 5 months ago

This is not part of the v1.9.6 release.