Forum Discussion
Eoclean-LH
Feb 18, 2019Copper Contributor
DataField visible Checkbox
Hi, I have a DataField called "Car" it should only be shown when the CheckBox "Car" is true. It works when I put this into Visible: If(Check_Car.Value=true;true) The problem is when you start a...
Alan Marshall
Feb 18, 2019Iron Contributor
Create a variable using the update context to store the a true false value and make it false by default or use an if to set based on the data, put this in onStart or Onvisible. Set visible value on your car data field to be the variable, it will always be true or false. On the checkbox add an on update to set the variable to the value of the checkbox field itself. I find it's always better to use a variable to store the show hide value rather than reference the field directly. If you need
Eoclean-LH
Feb 19, 2019Copper Contributor
Thank you. I set it like in this post:
https://powerusers.microsoft.com/t5/General-Discussion/Control-conditional-visibility/td-p/57476
Now I've the problem that when I view the list item the check boxes are "unchecked" and do not show the content in the form (see Word file)
- Alan MarshallFeb 19, 2019Iron ContributorThat post is the correct approach. Are your check boxes data associated with the field and the default is the item value?
You will need to add an Onvisible to also check if those checkboxes are true and update your context variable otherwise nothing will be visible in edit mode- Eoclean-LHFeb 20, 2019Copper Contributor
maybe the screenshots in the word file shows how I set it up.
But maybe I'm following the wrong solution.What I want:
I have a list with 8 options for people how Travel. Sometimes they need a Car, Hotel, Flight, Visa...
But sometimes maybe only a hotel.I want not to show all fields when start the APP. They can choose and then the field will be visible.
After this I send a mail to the travel agency and they need to see only the fields the Traveller choose