cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

CDS entity boolean field coming as dropdown instead of toggle

Hi ,

 

I'm facing an issue while creating an app with field of type boolean( Two options) from CDS 2.0,

the problem is that i'm unable to show the toggle button, the app automatically gives the YES/NO dropdown.

There is no option for changing the same to toggle.

 

Datatype is showing as complex instead of boolean in the edit field section, What could be the reason?

 

Thanks in advance

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: CDS entity boolean field coming as dropdown instead of toggle

Hi @Guruprasanna ,

Based on the issue tha you menitoned, I have made a test, and the issue is confirmed on my side.

 

When generating an app from a CDS Entity, the "Two Options" type column in CDS Entity would be generated into Dropdown box within the Edit form automatically.

 

If you want to use Toggle control to represents the "Two Options" type column within your Edit form instead of using Dropdown box, as an alternative solution, you could consider remove the Dropdown box from the "Two Options" data card, then add a Toggle control within it.

I have made a test on my side, please take a try with the following GIF screenshot:Test.gif

On your side, you need to unlock the "Enable subcategory" data card within your Edit form firstly. Then remove the Dropdown box from the "Enable subcategory" data card, and add a Toggle control within it.

Set the Update property of the "Enable subcategory" data card to following:

If(Toggle1.Value=true, 'IsOverdue (TaskLists)'.Yes, 'IsOverdue (TaskLists)'.No)

On your side, you should type:

If(Toggle1.Value = true, 'Enable subcategory (YourEntityName)'.Yes, 'Enable subcategory (YourEntityName)'.No)

Note: The "Two Options" type column in CDS Entity would be recognized as a Option Set type column within PowerApps. So when you specify value for the "Enable subcategory" column, you should reference values from the "Enable subcategory" column like 'Enable subcategory (YourEntityName)'.Yes.

More details about referencing values from Option Set type column within PowerApps app, please check the following blog:

https://powerapps.microsoft.com/cs-cz/blog/option-sets-and-many-to-many-relationships-for-canvas-app...

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Highlighted
Anonymous
Not applicable

Re: CDS entity boolean field coming as dropdown instead of toggle

Hi @Guruprasanna,

 

You just delete the dropdown of your form and then add a toggle in.

After that, change your card's Update Statement to set the value of your toggle and change the default value of your toggle to your list column's value.

 

Hope it will help you...

 

Best regards, 

 

Louis

Highlighted
Community Support
Community Support

Re: CDS entity boolean field coming as dropdown instead of toggle

Hi @Guruprasanna ,

Based on the issue tha you menitoned, I have made a test, and the issue is confirmed on my side.

 

When generating an app from a CDS Entity, the "Two Options" type column in CDS Entity would be generated into Dropdown box within the Edit form automatically.

 

If you want to use Toggle control to represents the "Two Options" type column within your Edit form instead of using Dropdown box, as an alternative solution, you could consider remove the Dropdown box from the "Two Options" data card, then add a Toggle control within it.

I have made a test on my side, please take a try with the following GIF screenshot:Test.gif

On your side, you need to unlock the "Enable subcategory" data card within your Edit form firstly. Then remove the Dropdown box from the "Enable subcategory" data card, and add a Toggle control within it.

Set the Update property of the "Enable subcategory" data card to following:

If(Toggle1.Value=true, 'IsOverdue (TaskLists)'.Yes, 'IsOverdue (TaskLists)'.No)

On your side, you should type:

If(Toggle1.Value = true, 'Enable subcategory (YourEntityName)'.Yes, 'Enable subcategory (YourEntityName)'.No)

Note: The "Two Options" type column in CDS Entity would be recognized as a Option Set type column within PowerApps. So when you specify value for the "Enable subcategory" column, you should reference values from the "Enable subcategory" column like 'Enable subcategory (YourEntityName)'.Yes.

More details about referencing values from Option Set type column within PowerApps app, please check the following blog:

https://powerapps.microsoft.com/cs-cz/blog/option-sets-and-many-to-many-relationships-for-canvas-app...

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
Resolver I
Resolver I

Re: CDS entity boolean field coming as dropdown instead of toggle

Hi there,

 

I've tried this solution, but cannot seem to get it to work. I can delete the drop down and insert a toggle, but I cannot seem to get it to connect back to the data source in the CDS. Any help would be super appreciated, as i have a number of these to insert into my app, and drop downs will be horrible to use!  

Thanks

C

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (6,873)