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 / Pass value from select...
Power Apps
Unanswered

Pass value from selection box to global variable

(0) ShareShare
ReportReport
Posted on by 76

I have a selection box in a form and am trying to pass the selected value to a global variable.  I have a submit button which submits the form.  The first step in OnSubmit is to pass the select box value to the variable.  What I have is:

 

Set(varNewOffboardingName, OffboardingNameSelectBox.SelectedItems.Name);
 
With the cursor positioned after "Name", it is showing that the data type is table.  I think this is why it is not passing the value to the variable.  But I'm struggle to find the solution. 
Categories:
I have the same question (0)
  • v-mengmli-msft Profile Picture
    on at

    Hi @StaceyGriffeth ,

     

    Your current formula is passing a single column table to the variable.

    For example.

    vmengmlimsft_0-1712591933700.png

     

    What does "Not pass" refers to? Is it the fact that when you click on a variable, the value is displayed as blank? Or the variable cannot be displayed on a control?

     

    Best regards,

    Rimmon

     

  • StaceyGriffeth Profile Picture
    76 on at

    Hi @v-mengmli-msft This selection box presents a list of names from a sharepoint list.  The selected name is what should be captured in the variable.  What I say it isn't passing to the variable, I mean that it is not setting the variable's value.  I checked this by adding a text label and setting the variable as the value.

  • StaceyGriffeth Profile Picture
    76 on at

    @v-mengmli-msft I got it to work by using Selected instead of SelectedItems

  • v-mengmli-msft Profile Picture
    on at

    Hi @StaceyGriffeth ,

     

    Glad to hear the problem has been solved, I will accept this reply as a solution to mark this problem is over.

    Thanks for using PowerApps.

     

    ————————————————————————————————————————————————————————————

    If my answer helps you solve the problem, please accept it as a solution.

    If you have another question, please post it as new question in the forum.

     

    Best regards,

    Rimmon

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…

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
Kalathiya Profile Picture

Kalathiya 445

#2
WarrenBelz Profile Picture

WarrenBelz 386 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 321 Super User 2025 Season 2

Last 30 days Overall leaderboard