PerformanceImplementation TIps - Question about "Use Shape Identifier"

Find and share HowTos to various installations / configurations!
Search

Post Reply
2 posts • Page 1 of 1
tobias_raab
Posts: 18
Joined: Mon Feb 29, 2016 3:30 pm

PerformanceImplementation TIps - Question about "Use Shape Identifier"

Post by tobias_raab »

Hi,

I'm not sure where to post this question so I just put it in here.

In the document "WP_PerformanceImplementationTips_EN_1.0" you suggest in "6.16 Use Shape Identifier" to use shape identifier if a shape has to be changed in a regular fashion.


In my case I have panels with buttons, text fields, ..., which are changed in terms of visibility, enabled status, backCol, ..., depending on the selected datapoint and user actions. So those attributes might be changed multiple times while the panel is active.
The question here is if it is a performance enhancement to store all shape identifiers in a mapping with the shape strings and use this mapping in my scripts.
Or if the lookup in the mapping is performance wise the same load as if using the setValue / setMultiValue with the shape string instead of the shape identifier.

Case1:
setMultiValue("TEXTFIELD_BLA_1", "text", "xxx",
....
"TEXTFIELD_BLA_X", "text", "xxx");

Case2:
mapping mShapeIDs;
// get a mapping shape strings : shape ids
....
setMultiValue(mShapeIDs["TEXTFIELD_BLA_1"], "text", "xxx",
....
mShapeIDs["TEXTFIELD_BLA_X"], "text", "xxx");


Best regards,
Tobias Raab

User avatar
leoknipp
Posts: 2926
Joined: Tue Aug 24, 2010 7:28 pm

Re: PerformanceImplementation TIps - Question about "Use Shape Identifier"

Post by leoknipp »

Using the shape identifier instead of the object name has a big advantage if you have panels with a high number of shapes, e.g a panel with several hundred shapes.
When the number of shapes is not that high there is no need to use the shape identifier.

Even if using a shape identifiert there is no need to use a mapping to store the list of shapes.
You can simply use the shape id instead of the object name.

Best Regards
Leopold Knipp
Senior Support Specialist

Post Reply
2 posts • Page 1 of 1