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

Save and display value of combobox

hi,

 

i create a new collect by click a button

 

Collect.png

 

add a new gallery by using source data from collect "tblNewItemData"

Gallery.png

in the combobox is set datasource from collect "tblMaterialMaster.Title"

when user is able to add new item dataTransaction.png

using plus sign to add new line item:

 

Patch(tblNewItemData,ThisItem, {Product:(LookUp(tblMaterialMaster,Title=cbProductName.Selected.Title,Product)),ProductName:cbProductName.Selected.Title, DelQty: Value(txtQty.Text), BaseUnit:txtBaseUnit.Text, ShipTo: txtShipTo.Text, ShipmentNo: txtShipmentNo.Text, VesselNo: txtVessel.Text, ItemText: txtItemText.Text, New:"Added"}); Collect(tblNewItemData, {Product:"", ProductName:"", DelQty: "", BaseUnit:(LookUp(tblMaterialMaster,Title=cbProductName.Selected.Title,Base_Unit.Value)), ShipTo: "", ShipmentNo: "", VesselNo: "", ItemText: "", New:"New" })

 

the problem is combobox doesn't update and display blank

blnak.png

 

how to fix this problem?

 

Thanks,

Ratana

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Save and display value of combobox

Hi @ratanapouy ,

Could you please share a bit more about the cbProductName? Is it the ComboBox within your Gallery?

Could you please show more details about the DefaultSelectedItems property formula of the cbProductName in your Gallery?

 

Please consider set the DefaultSelectedItems property formula of the cbProductName ComboBox in your Gallery to following formula:

{
   Title: ThisItem.ProductName
}

set the Items property of the cbProductName ComboBox to following:

tblMaterialMaster.Title

Please take a try with above solution, then 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.

View solution in original post

5 REPLIES 5
Super User
Super User

Re: Save and display value of combobox

What is the default property formula for cbProductName (added).



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
shailendra74
Level 10

Re: Save and display value of combobox

Hi @ratanapouy 

 

Also can you check the below:

 

The datasource of combobox is set to collection - tblMaterialMaster

 

when you add new record, you can write Collect(tblNewItemData, {}) // defaults will be considered

 

Also you need not have "+" icon for each row, it can be placed above the gallery

 

Thanks.

Super User
Super User

Re: Save and display value of combobox

If the item got added to tblNewItemData correctly using Collect() and ProductName has the correct value but isn't showing in the combobox afterwards then it most likely has to do with how the Default/DefaultSelectedItems is configured.

 

I understand that the combobox has the Items property set to tblMaterialMaster but is the formula used for the properties Default and DefaultSelectedItems? 



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Community Support Team
Community Support Team

Re: Save and display value of combobox

Hi @ratanapouy ,

Could you please share a bit more about the cbProductName? Is it the ComboBox within your Gallery?

Could you please show more details about the DefaultSelectedItems property formula of the cbProductName in your Gallery?

 

Please consider set the DefaultSelectedItems property formula of the cbProductName ComboBox in your Gallery to following formula:

{
   Title: ThisItem.ProductName
}

set the Items property of the cbProductName ComboBox to following:

tblMaterialMaster.Title

Please take a try with above solution, then 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.

View solution in original post

Highlighted
ratanapouy
Level: Powered On

Re: Save and display value of combobox

(added) below cbProductName is an indicator textbox to identify it is new item or saved item.

Helpful resources

Announcements
thirdimage

Power Automate 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

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 169 members 4,524 guests
Please welcome our newest community members: