Issue with protected PPT in Office 2016

We had implemented code for PPT locked and works with office 2013 as per desired.

Unfortunately, it doesn’t work wtih office 2016 at all. Any object of slides are not locked.

Please provide few suggestion for the same.

It is urgent.

Regards,
Ritesh Kothari

Hi Ritesh,


I have observed your comments. I request to you please share the source code and presentation so that we may further investigate the issue.

Best Regards,
Hello,

Please find code as per bellow.

--------------------------------------------------------

private void LockSlide(Presentation destPres)

{

ISlide slide1 = destPres.Slides[0];

for (int slideCount = 0; slideCount < destPres.Slides.Count; slideCount++)

{

slide1 = destPres.Slides[slideCount];

IShape shape;

//Travesing through all the shapes in the slides

for (int count = 0; count < slide1.Shapes.Count; count++)

{

shape = slide1.Shapes[count];

//if shape is autoshape

if (shape is IAutoShape)

{

//Type casting to Auto shape and getting auto shape lock

IAutoShape Ashp = shape as IAutoShape;

IAutoShapeLock AutoShapeLock = Ashp.ShapeLock;

//Applying shapes locks

AutoShapeLock.PositionLocked = true;

AutoShapeLock.SelectLocked = true;

AutoShapeLock.SizeLocked = true;

}

//if shape is group shape

else if (shape is IGroupShape)

{

//Type casting to group shape and getting group shape lock

IGroupShape Group = shape as IGroupShape;

IGroupShapeLock groupShapeLock = Group.ShapeLock;

//Applying shapes locks

groupShapeLock.GroupingLocked = true;

groupShapeLock.PositionLocked = true;

groupShapeLock.SelectLocked = true;

groupShapeLock.SizeLocked = true;

}

//if shape is a connector

else if (shape is IConnector)

{

//Type casting to connector shape and getting connector shape lock

IConnector Conn = shape as IConnector;

IConnectorLock ConnLock = Conn.ShapeLock;

//Applying shapes locks

ConnLock.PositionMove = true;

ConnLock.SelectLocked = true;

ConnLock.SizeLocked = true;

}

//if shape is picture frame

else if (shape is IPictureFrame)

{

//Type casting to pitcture frame shape and getting picture frame shape lock

IPictureFrame Pic = shape as IPictureFrame;

IPictureFrameLock PicLock = Pic.ShapeLock;

//Applying shapes locks

PicLock.PositionLocked = true;

PicLock.SelectLocked = true;

PicLock.SizeLocked = true;

}

}

}

}

---------------------------------------------------------

Hi Ritesh,


I have worked with source code shared by you using Aspose.Slides for .NET 16.7.0 and unable to observe the issue. I like to share that we have tested our presentation with your source code and it seems to work fine in PowerPoint 2016. Please verify our generated presentation on your end. If there is still an issue share your source and generated presentation so that we will verify on our end. Please see attachments.

Best Regards,

I opened the attached file. It is not locked. I can change the content.

please find attached screenshot.

Thanks.

Hi Adnan -

One nuance I wanted to bring to your attention after reviewing your locked PPT example. It seems that shapes are locked but content/text within the shapes isn’t. I can edit/delete without any issues. You can check “test” which you have within the rectangle, I can easily edit that which shouldn’t be the case once the PPT is locked in 2016.

Thanks,
Ritesh

Hi Adnan -

Any updates on the issue?

Thanks!

Hi Ritesh,


I have worked with the presentation shared by you using Aspose.Slides for .NET 16.7.0 and have been able to observe the issue. A ticket with ID SLIDESNET-37833 has been added in our issue tracking system to resolve the issue. This thread has been associated with the ticket so that we share notification with you once issue will be fixed.

We are sorry for your inconvenience,

Hi Ritesh,


Our product team is investigating issue in details and unable to observe the issue in PowerPoint 2016. Can you please share your PowerPoint version which you are using on your end so that we can make further investigation regarding this issue.

Best Regards,

Hi Adnan,

As per your previous comment, you observed locked file issue with Office 2016 for Aspose.Slides for .NET 16.7.0.

Have your team test with same version Aspose.Slides?

Currently we faced the locked presentation issue with Office 2016 (Version: 16.0.6868.2062).

Thanks

Hi Ritesh,


Thank you for sharing information with us. We will get back to you with feedback soon.

Best Regards,

The issues you have found earlier (filed as SLIDESNET-37833) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.

Hello,




We have integrated new dll (ver. 16.11.0) with existing project.
Unfortunately, Issue is still not fixed. I faced same problem with office 2016.




Thanks.

Hi Ritesh,


I have observed your comments. I like to inform that code snippet is provided by product team which i like to share with you. Please see attachments.

Best Regards,

Hello,



Thanks for providing code snippet for locked presentation. It works with office professional version of office 2016.




Unfortunately, it doesn’t work with Microsoft Office 365 ProPlus version. Please look into that. Here I attached screenshot of office version where this code doesn’t work.



Thanks.

Hi Ritesh,

I have shared the information with our product team regarding Office 365 ProPlus version We will get back to you with a feedback as soon as it will be shared by our product team.

Many Thanks,

Hi Ritesh,


Our product team has investigated the issue on their end. Actually, Office 2016 has problem with text blocking. We have tested presentation in Office 365 version 16.0.6925.1041 as mentioned in attached image.

Please try to update your Office. and also try to add code:



blockerShape.AutoShapeLock.TextLocked = true;

Many Thanks,

The issues you have found earlier (filed as SLIDESNET-37833) have been fixed in Aspose.Slides for .NET 18.1. Please try using the latest release version and in case you experience any issue or you have any further query, please feel free to contact.