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 / Toggle value in edit.f...
Power Apps
Answered

Toggle value in edit.form based on excel

(0) ShareShare
ReportReport
Posted on by 77

Hi there,

 

it seems that I'm just too stupid today.

 

So, I have a gallery based on a collection. When I click a symbol, it opens a form in edit mode:

 

ClearCollect(colWaiverEdit;Filter(Table1_1;WaiverID=ThisItem.WaiverID));;
Navigate(New_Waiver_1;CoverRight)

 

then I have toggles in the form, both based on an text field in excel (values "important", "not important".

 

But no matter what I try, the toggles seem to have random values when I open the form.

 

I currently have un the Default value

 

if(thisitem.Importance ="important";true;false)

 

All the rest works, so when I change the value and submit, the underlying data will update and the excel table shows the new value but when I open the form the next time, it has not necessarily something to do with the underlying data.

 

Any good ideas?

 

Thanks, SVM 

 

 

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    156,327 Most Valuable Professional on at

    HI @svm75 ,

    You actually only need

    ThisItem.Importance ="important"

    on the Default of the toggle  OR if case it the issue "Important", "important"

    StartsWith(
     ThisItem.Importance;
     "important"
    )

    I assume it is in a card in the form?

     

    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.

    Visit my blog Practical Power Apps

  • svm75 Profile Picture
    77 on at

    Hi @WarrenBelz ,

     

    yes, it is in a card. 

    Where would the STARTSWITH… go? Also in the default of the toggle?

     

    thanks. SVM 

  • WarrenBelz Profile Picture
    156,327 Most Valuable Professional on at

    Hi @svm75 ,

    Yes on the Default - you simply make a statement in both cases that has to be either true or false and this is then reflected in the Default of the Toggle (which is also either true or false),

     

    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.

    Visit my blog Practical Power Apps

  • svm75 Profile Picture
    77 on at

    Hi @WarrenBelz ,

     

    unfortunately I doesn’t work. 

    When I open the form, it shows whatever I had selected in the last form but not what is stored in the Excel for that specific record. Any other thought?

  • WarrenBelz Profile Picture
    156,327 Most Valuable Professional on at

    Hi @svm75 ,

    There is something else wrong here as this is a simple true/false exercise. Put a Label inside the toggle card (you will have to unlock it) with 

    ThisItem.Importance

    and see what value is in there. What is the Item of the Form? Also I assume the form is in Edit or View Mode ? 

     

  • svm75 Profile Picture
    77 on at

    Hi @WarrenBelz ,

     

    the form is in Edit mode. 

    the label shows the correct value (ie the one that is stored in the DB. But the toggle doesn’t. As it seems, the toggle always shows the value that was set when the form was used the last time but not the value of the record. 

  • Verified answer
    WarrenBelz Profile Picture
    156,327 Most Valuable Professional on at

    Hi @svm75 ,

    So I am clear here - you have a card with two items in it now - a Toggle with the Default

    ThisItem.Importance ="important"

    and a Label with the Text

    ThisItem.Importance

    which is displaying important  and the Toggle is not true / on ?

     

  • svm75 Profile Picture
    77 on at

    hi @WarrenBelz ,

     

    correct. While the label shows the record value, the toggle is always at the value of when I closed the form previously

  • WarrenBelz Profile Picture
    156,327 Most Valuable Professional on at

    @svm75 ,

    Can you please post a screenshot of that - it makes no sense unless you have a corrupt control.

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 July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 392 Most Valuable Professional

#2
11manish Profile Picture

11manish 181 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 112 Super User 2026 Season 2

Last 30 days Overall leaderboard