When I use the Shapes.FindShapes API to find objects, how can the first parameter Shape. Name be unrestricted? If I don't fill it in, only objects with an empty Name property can be matched
Here are a few example of FindShapes. None of them use name.
Find Text ShapesActivePage.FindShapes(, cdrTextShape)ActivePage.FindShapes(Type:=cdrTextShape)
Find Rectangle ShapesActivePage.FindShapes(Type:=cdrRectangleShape)
Using CQL Find all ContoursActivePage.Shapes.FindShapes(Query:="@type='contour'")
Find All ShapesActivePage.Shapes.FindShapes()
Let me know if you need any more.
-Shelby
Thank you but it seems that it cannot be used in JavaScript. When passing parameters in JavaScript, it is not allowed to leave them blank. The default value is undefined. When filling in undefined, only shapes with an empty Name property can be matched. For example:const pageShapes = host.Application.ActivePage.Shapes;const result = pageShapes.FindShapes(undefined, undefined, undefined, "@width >= {5 mm}");
Javascript functionality is so limited that I don't use it. If I get a minute I will try and play with it, see what I can find.
Thanks,Thank you for helping me before.
With your guidance, I have solved many problems, including but not limited to building a UI based on front-end design in CorelDRAW