web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Can I set the data-set...
Power Apps
Unanswered

Can I set the data-set property cds-data-set-options through a parameter?

(1) ShareShare
ReportReport
Posted on by 32

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

 

I have the same question (0)
  • a33ik Profile Picture
    3,306 Most Valuable Professional on at

    Hello,

    I'm afraid this Control Manifest parametrization is not something you could achieve.

  • akatakkar Profile Picture
    32 on at

    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. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 793 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 333 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard