I've a dataverse database.
In my database I've a yes/no column, called tasktype.
When I try to set a label in my gallery that show the name record when task type is set on Yes and if it's Set on No, it should be show the value of a dropdownlist.
Now I'm strubeling to achieve this. (I've done it a lot of times with SharePoint as datasource, but now with dataverse it will not work properly.)
If(ThisItem.TaskType ="Yes",ThisItem.Name,ThisItem.'Task (Pre_task)')
Does anyone how to achieve it / Why it's not working?
Solved! Go to Solution.
If you are setting it for a label, you will not get "ThisItem" object instead use "BrowseGallery1.Selected.yourfield".
If you are trying to set for any datacard, a field which available in table/entity then ThisItem object will be available.
Try below, I have used custom label. To check for optionset, you have to use optionset value instead of string like below.
Find is yes or no option set with values allowed and not allowed.
If(BrowseGallery1.Selected.Find = 'A Yes or No boolean'.Allowed, BrowseGallery1.Selected.Name, "yes")
If it answers your question, kindly give kudo and accept is as solution.
Keep up to date with current events and community announcements in the Power Apps community.
A great place where you can stay up to date with community calls and interact with the speakers.
Check out the latest Community Blog from the community!