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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Changing an icon's ima...
Power Apps
Unanswered

Changing an icon's image when selected (pressed)

(0) ShareShare
ReportReport
Posted on by 72

Hello all, 

 

Is there a way that when an icon is pressed it changes its 'image'?

 

I'm trying to have a lock icon that when pressed it becomes an unlocked icon and vice versa.

 

Thanks in advance!

Categories:
I have the same question (0)
  • Verified answer
    Pstork1 Profile Picture
    68,697 Most Valuable Professional on at

    Add an Icon to your screen. Set the OnSelect to the following

    Set(varlocked, Not(varlocked))

    set the Icon property to the following.

    If(varlocked,Icon.Lock,Icon.Unlock)

    The OnSelect will toggle between the two states whenever the icon is clicked and the Icon property will show the Locked or unlocked icon based on the state.

     

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard