cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
hannie0906
Level: Powered On

Can we pull data from SP without using form?

Hello everyone,

 

I have a screen with various combo boxes . It is not a form or datacards, the reason I dont use a Form is because each drop down option is associated to a number to create a Gauge (Picture below)

Capture.PNG

I saved all the data from the combobox using a Patch fucntion to a Sharepoint list.

 

Here is my problem:

 

I want to click a record in a gallery (data from that SP list) and then it takes the ID of the record and pulls back the data from the list (same idea of Edit Form). It then navigates to the same screen (attached picture above) with already populated previous choices. 

 

Any help is appreciated.

 

Thanks,

Q

 

4 REPLIES 4
Dual Super User
Dual Super User

Re: Can we pull data from SP without using form?

Hi @hannie0906 

 

When user Navigates to the edit screen, you can also Set a variable which includes the ID of the record to edit

 

Then in your edit screen, use lookup function to get data and select default for all your dropdowns

 

Note, when user clicks on new screen request, make sure to set variable to empty

 

On your new/edit screen you can check variable to determine what needs to be done

New screen - empty variable - set empty for dropdowns

Edit screen - variable has value - get the data for the specific ID and set defaults for your dropdowns

 

Regards,

Reza Dorrani

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

hannie0906
Level: Powered On

Re: Can we pull data from SP without using form?

Hi @RezaDorrani 

 

Thank you for the suggestion. I appologize for my limited knowledge in advance.

 

Can you please give a more specific example on how to set a variable to get the data for the specific ID and set defaults for your dropdowns.

 

Thanks,

Q

Dual Super User
Dual Super User

Re: Can we pull data from SP without using form?

Hi @hannie0906 

 

Variables

example Set(var,"test")

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/working-with-variables

 

 

Default value for dropdown

https://powerusers.microsoft.com/t5/General-Discussion/How-to-set-up-drop-down-default-value-to-a-te...

Depends upon how you are populating the dropdown list in the first place - what is your data source

Also, when you are storing in SharePoint list, using Patch what type of column are you storing it in?

 

Regards,

Reza Dorrani

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

 

 

Community Support Team
Community Support Team

Re: Can we pull data from SP without using form?

Hi @hannie0906 ,

Do you want to populate the ComboBox based on the selected item in your Gallery?

How do you store the ComboBox value within your SP List? Using Single text column or Choice type column?

 

Based on the needs that you mentioned, I think the global variable could achieve your needs. I have made a test on my side, please take a try with the following workaround:

Set the OnSelect property of the Gallery to following:

Set(CurrentItem, ThisItem)

Then set the DefaultSelectedItems property of the Exclusivity (Multiple) ComboBox to following:

{
  Value: CurrentItem.Exclusivity
}

set the DefaultSelectedItems property of the Confidentiality (Single) ComboBox to following:

{
  Value: CurrentItem.Confidentiality
}

set the DefaultSelectedItems property of the Liability Cap (Single) ComboBox to following:

{
  Value: CurrentItem.'Liability Cap'
}

...

...

 

Note: I assume that you could only select single one value within each ComboBox. And the Exclusivity, Confidentiality, 'Liability Cap', ... are all columns in your SP list.

 

If you want to clear selected item within your Gallery, you could consider add a Button control (called "Reset"), set the OnSelect property to following:

Set(CurrentItem, Blank())

Please take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (4,197)