I attempted to use this method, UnlockAllShapes, on the master page in a document in CorelDraw 2017 and it did not work. I did this using C#. My code specifically was
Application.ActiveDocument.MasterPage.UnlockAllShapes();
For whatever reason this code does not seem to work. The next thing I attempted was a workaround using CQL. Specifically:
ShapeRange lockedShapes = corelDrawDocument.MasterPage.Shapes.FindShapes("@com.locked = true"); ShapeRange lockedShapes = Page.Shapes.FindShapes("@com.locked = true");
Neither of these function calls returned any shapes even though I know they should work. Does anyone know why this could would not function in CorelDraw 2017?
I have no experience in C#, so I don't know how the syntax might differ, but this works for me in VBA:
1
ActiveDocument.MasterPage.Shapes.FindShapes(Query:="@com.locked = 'true'").Unlock
This works for me in X7.
Just realized you're speaking of the "Master Page". Do you mean Master Layer (all pages)? Could probably tweak this code a bit to get you there.
Sub UnlockAllShapes()Dim x#, y#, w#, h#, p As Page, doc As Document Set doc = Application.ActiveDocumentOn Error GoTo ErrHndler
For Each p In doc.Pagesp.Shapes.FindShapes.Lock p.Shapes.FindShapes.Unlock Next pErrHndler:Err.ClearEnd Sub