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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Set Yes/No column to t...
Power Apps
Suggested Answer

Set Yes/No column to true based on Datacard visible property

(4) ShareShare
ReportReport
Posted on by 142
I have a below field in Powerapps with SharePoint as the backend. I need to set the Yes/No column to true based on the Datacard visible property. I tried below code which includes Self.Visible=true, but it doesn't work. May i know why?
 
DataCard Visible Property
varCurrentTab = "Communications" && With(
    {
        _Data: Filter(
            'DS',
            'Process Type'.Value = Trim(DataCardValue48_2.Selected.Value) && 'Resource Type'.Value = Trim(DataCardValue6_1.Selected.Value)
        )
    },
    LookUp(
        _Data,
        "YouTubeSubscribe" in 'Field to be hidden'.Value,
        'Hide?'
    ) = false || IsBlank(
        LookUp(
            _Data,
            "YouTubeSubscribe" in 'Field to be hidden'.Value
        ).'Hide?'
    )
)
 
DataCard Update Property
DataCardValue66_2.Value&&Self.Visible=true
Toggle Default Property
Parent.Default
 
I have the same question (0)
  • Suggested answer
    oyepanky Profile Picture
    563 on at

    Hi @Poweruser32490,

    The issue is that the Update property doesn't reliably evaluate Self.Visible the way the Visible property does. Also, Self.Visible = true is unnecessary because Visible already returns a Boolean value.

    If you want the SharePoint Yes/No column to reflect the visibility of the DataCard, use the same visibility condition directly in the Update property, for example:

    varCurrentTab = "Communications" &&
    With(
        {
            _Data: Filter(
                'DS',
                'Process Type'.Value = Trim(DataCardValue48_2.Selected.Value) &&
                'Resource Type'.Value = Trim(DataCardValue6_1.Selected.Value)
            )
        },
        LookUp(
            _Data,
            "YouTubeSubscribe" in 'Field to be hidden'.Value,
            'Hide?'
        ) = false ||
        IsBlank(
            LookUp(
                _Data,
                "YouTubeSubscribe" in 'Field to be hidden'.Value
            ).'Hide?'
        )
    )
    

    Or store that expression in a variable and use the variable in both the Visible and Update properties. This avoids duplicating the logic and keeps both properties in sync.
     

    Best Regards,
    Pankaj Jangid (OyePanky)
    Power Platform Developer
    YouTube: https://www.youtube.com/@oyepanky
    Website: https://dialforit.com

  • Suggested answer
    11manish Profile Picture
    3,788 on at
    Avoid using Self.Visible in the Update property. Instead, reuse the same expression used in the Visible property or store it in a variable (such as varShowYouTubeSubscribe) and reference that variable in both places. This is the recommended Power Apps pattern because it improves readability, avoids duplicated logic, and ensures consistent behavior.
  • WarrenBelz Profile Picture
    156,229 Most Valuable Professional on at
    I will firstly get you to confirm exactly what you are trying to set the (I assume) Named Formula varCurrentTab to here. The first part ​​​​​​"Communications" is a string value and the rest results in a Boolean true/false output. I assume you want a Boolean output here to set the Visible property of the object.
     
    You can also save a bit of code here (assuming the 'Hide?' field in your DS data source is a Boolean) by setting the Default value to false as a Boolean field should never be blank.
     
    Can you please confirm the field type and Default value of Hide and why the string is in the Formula.
     
    Please Does this answer your question 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 answering Yes to Was this reply helpful? or give it a Like
    Visit my blog
    Practical Power Apps    LinkedIn  
  • Suggested answer
    Valantis Profile Picture
    6,967 on at
     
    To get a file from OneDrive in Power Apps and pass it to a flow, use the OneDrive for Business connector.
     
    In Power Apps:
    1. Add OneDrive for Business as a data source
    2. Use OneDriveForBusiness.GetFileContent(filePath) to get the file content
    3. Pass the result to your flow: YourFlow.Run(OneDriveForBusiness.GetFileContent(filePath))
    In your Power Automate flow:
    1. The trigger When Power Apps calls a flow should have a File input parameter (not text)
    2. The flow receives the file content as base64, which you can then use in connectors like Send an email, Create file in SharePoint, etc.
     
    If you know the file path in advance, you can hardcode it. If the user selects the file, use an Attachment control or let the user type/select the path.
     
    What exactly are you trying to do with the file after passing it to the flow? That'll help confirm the best approach.
     
      Best regards,

    Valantis   ✅ If this helped solve your issue, please Accept as Solution so others can find it quickly.

    ❤️ If it didn’t fully solve it but was still useful, please click “Yes” on “Was this reply helpful?” or leave a Like :).

    🏷️ For follow-ups  @Valantis.

    📝 https://valantisond365.com/ 💼 LinkedIn ▶️ YouTube
  • WarrenBelz Profile Picture
    156,229 Most Valuable Professional on at
    A quick follow-up to see if you received the answer you were looking for. Happy to assist further if not.
     
    Please Does this answer your question 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 answering Yes to Was this reply helpful? or give it a Like ♥
    Visit my blog
    Practical Power Apps    LinkedIn   

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 353 Most Valuable Professional

#2
11manish Profile Picture

11manish 150

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 68 Super User 2026 Season 1

Last 30 days Overall leaderboard