cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
RM365
New Member

Simple If statement in custom sharepoint list form

Hi, I have a really simple concept that I just cannot get to work. I am customizing a SharePoint list form and I want to control the visibility of a lookup field based on the setting of a Yes/No toggle in the preceding question.

 

i thought something like this would work: If(DataCardValue6.Value=1,true,false) in the Visible function of the lookup field.

 

DataCardValue6 is the Yes/No toggle in the preceding question

I have tried 1 / On / Yes in the logic and nothing works

 

what am i doing wrong?!

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @RM365 ,

Simply set the Visible of the Lookup control to 

DataCardValue6.Value

If it is true, then the Visible will be also true (and the opposite)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

4 REPLIES 4
WarrenBelz
Super User
Super User

Hi @RM365 ,

Simply set the Visible of the Lookup control to 

DataCardValue6.Value

If it is true, then the Visible will be also true (and the opposite)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

Nogueira1306
Community Champion
Community Champion

That DataCard returns 2 values (true or false)

So, if you put 

 

DataCardValue6.Value

 

 

on visibility, it will solve your problem 

@Nogueira1306 ,

Just what I posted about 10 minutes before . . .

Told you it was simple - thanks @WarrenBelz - works a charm

and thanks @Nogueira1306 also!

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,161)