Hello,
We currently have a PCF with the following in the Control Manifest file:
<data-set name="dataset" display-name-key="dataset" cds-data-set-options="displayCommandBar:false;displayViewSelector:true;displayQuickFind:true"></data-set>
We'd like to have the ability to configure 'displayCommandBar' as we need an additional PCF that is almost identical but we will not display the command bar. Is it possible to set the value through a parameter, or is this impossible?
i.e. Is something like this possible?
<data-set name="dataset" display-name-key="dataset" cds-data-set-options="displayCommandBar:{property.displayCommandBarParam};displayViewSelector:true;displayQuickFind:true">
</data-set>
<property name="displayCommandBarParam" display-name-key="displayCommandBarParam" description-key="If set to true display command bar, otherwise do not." of-type="TwoOptions" usage="input" required="false" default-value="false" />
We are assuming the alternative is to create another PCF with one of the only differences being displayCommandBar is set to true. Unfortunately this will result in a lot of code duplication, unless we create some common code directories. This seems a bit clunky.
Thanks in advance
Ok - thanks for confirming that.
I cannot think of any other way to do this, other than duplicating almost identical component code. From what I gather, it would be very tricky to create a common library that is shared between 2 components because of the generated code.
Hello,
I'm afraid this Control Manifest parametrization is not something you could achieve.
WarrenBelz
55
Most Valuable Professional
mmbr1606
42
Super User 2025 Season 1
Michael E. Gernaey
31
Super User 2025 Season 1