Question
Pegasystems Inc.
JP
Last activity: 18 Jul 2017 10:29 EDT
How to specify multiple formats for a control conditionally
Many end users want to highlight a control on the screen with different colors according to the value of the property bound with the control.
The common approach is defining multiple controls that are bound to the same property and specify different format for each control, then using a visible when rule to handle which control to be displayed at run time. However this approach makes a section rule not easy to comprehend and the value of WYSIWYG editor is undermined.
***Updated by moderator: Lochan to close post***
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Pegasystems Inc.
JP
Enhancement request has been raised as FDBK-12103.
Pegasystems Inc.
IN
Pegasystems Inc.
JP
Pegasystems Inc.
IN
sorry Chunzhi for not being clear. its a CUSTOM control to be configured to the property which could be parametrized...
Please share your thoughts/comments, Thank you!
psahukaru
Pegasystems Inc.
JP
How difficult it is to make a product enhancement, so it is possible to specify multiple "Control format" or "Label format" conditionally as "Edit option" does?
I have raised an enhancement request regarding this topic from my support portal.
SR-A2668: Specify multiple formats for a control conditionally
Pegasystems Inc.
US
Hello Chunzhi,
I have added a reference in the SR to this community discussion to assist in the clarification of the case.
Accepted Solution
Pegasystems Inc.
JP
Enhancement request has been raised as FDBK-12103.
Pegasystems
US
>>> the value of WYSIWYG editor is undermined.
I'm not sure how you can expect that WYSIWYG during editing since you don't know the value the property will have.
However, perhaps a fairly simple way to do this is to make several copies of a small section, each of which displays the property with the same control but with different choices for the control's parameters.
Then, from an outer section, include all the copies of the small section, but with visible-when conditions on each inclusion so that only one copy is visible, according to the property's value.
/Eric
Updated: 3 Jul 2015 8:08 EDT
Pegasystems Inc.
JP
At design time we can not expect the section editor renders the format of a control dynamically according to the value of the property bound to the control. However the section editor is (and should be) able to display the default format of a control at design time and it is better than displaying multiple controls at design time for a single property.
I don't think creating multiple sections for a single property is an easier way than just defining multiple controls for a single property.
Pegasystems
US
The reason I think creating multiple sections is easier than creating multiple controls is that the visible-when feature of the design layer makes it easy to show or not show a section, but I don't know if it's as easy to make it use or not use a control. /Eric