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 / Having a lot of troubl...
Power Apps
Unanswered

Having a lot of trouble with a variable to simply set the status of a record

(0) ShareShare
ReportReport
Posted on by 380

I have posted this question before and managed to solve the problem by removing an erroneous combo box from a DataCard but this time it is back to not working and it seems that I just can't set the variables at all..

 

I have an app which records field trips. A trip has a status which can be:

"Entered" (the end user has entered the trip but not yet submitted it for approval)

"Pending" (the end user has entered the trip and HAS submitted it for approval)

"Approved" (the approver has inspected the trip details and HAS approved the trip)

"Cancelled" (the end user has decided to cancel the trip)

 

status is a choice column in my Sharepoint List

 

I am using a Global variable called varstatus to hold the value which is set from the OnSelect property of 4 buttons on my form

Matching those values above, the OnSelect properties are:

Set(varstatus,"Entered")

Set(varstatus,"Pending")

Set(varstatus,"Approved")

Set(varstatus,"Cancelled")

 

I then have a combobox on the form which is designed to hold the value of varstatus and update that record in the datasource (Sharepoint list) when the form is submitted.

 

 

Items property of the combobox: Choices([@Trips].status)
DefaultselectedItems: Table({Value: varstatus})
Default: Parent.Default
Card Default: ThisItem.status

 

One thing I noticed is that when I go to Variables the varstatus variable shows up in Global Variables and 2 other screens - all of which have no value despite me setting a value manually.

I created a test button to just submit set the variable's value but it's not doing anything...

I know this is probably a very simple issue but I can't seem to get it to work - any help much appreciated 🙂

Categories:
  • bobgodin Profile Picture
    380 on at

    have found the problem - for some uncanny reason I had 2 comboboxes in the datacard - only just saw the second one when I made my window larger so the one I thought was updating the datasource was doing nothing!!

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
11manish Profile Picture

11manish 393 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 278 Most Valuable Professional

Last 30 days Overall leaderboard