cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Multi save data in excel

Hello friends.

 

i has tried, but i didn't have success.
i want change a multiple information in a excel file, this is the exemple:

CHNAGE 1.JPG

This is the extract bank statemen, i want to change the name providier, the same data is the supplier's reference account, i filter the information in the first textbox1 (Tb1), second the provider name in the textbox2 (Tb2),  with the button Multi, i want change my gallery, in the seccion "PROVIDER".

 

The issue:

i was use Patch, but it show a wrong. "type of argument not valid (Table). A Record value was expected instead"

Please, help me with my problem, i really want learn power apps.

 

My database: "_B2019"

Table1: Date

Table2: Concept

Table3: Amount

Table4:Provider

 

my supposed function:

 

Patch(BrowseGallery2.Selected;BrowseGallery2.Selected.PROVEEDOR;{PROVEEDOR:Textinput2.text})

or direct

Patch(_B2019;_B2019.Providier;{PROVIDER: Textinput2.Text})

 

What am i doing wrong?

 

Regards friends.

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Anonymous ,

Do you want to change all rows in your _B2019 data source based on the matched Concept?

 

Based on the needs that you mentioned, I think the ForAll function could achieve your needs. Please consider take a try with the following workaround:

Set the OnSelect property of the "Mul" button to following:

ForAll(
         RenameColumns(Filter(_B2019; TextSearchBox2.Text in 'Concept'); "PrimaryColumn"; "PrimaryColumn1");
Patch(
_B2019;
LookUp(_B2019; PrimaryColumn = PrimaryColumn1);
{
PROVEEDOR: TextInput3.Text
}
) )

Note: The PrimaryColumn represents the primary column in your _B2019 data source, which could identify one record uniquely in your _B2019 data source.

 

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

 

More details about the ForAll function and RenameColumns function, please check the following article:

ForAll function

RenameColumns function

 

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

3 REPLIES 3
myke_deabreu
Resolver III
Resolver III

Hi Diego,

 

I have never patched to Excel but I am sure it is the same as many other data sources. Try and filter on the unique key when you are patching and it should do the trick:

 

I think your key is : PROVEEDOR (Not sure. if it is not please change this with your unique key)

 

Patch(_B2019,First(Filter(_B2019, PROVIDER=gallery.selected.PROVIDER)),{PROVIDER:TextInput2.text})

 

Give that a try and let me know if it works for you.

Anonymous
Not applicable

thanks @myke_deabreu , you helped me to solve the first issue

this is the formula:

Patch(_B2019;First(Filter(_B2019;TextSearchBox2.Text in 'Concept'));{PROVEEDOR: TextInput3.Text})

the issue, i want change all the rows, but the condition First, only let me change one concept.

i tried use FirstN and ForAll, but i only can use First.

Could you have some idea?

Thanks for all.

Regards.

Hi @Anonymous ,

Do you want to change all rows in your _B2019 data source based on the matched Concept?

 

Based on the needs that you mentioned, I think the ForAll function could achieve your needs. Please consider take a try with the following workaround:

Set the OnSelect property of the "Mul" button to following:

ForAll(
         RenameColumns(Filter(_B2019; TextSearchBox2.Text in 'Concept'); "PrimaryColumn"; "PrimaryColumn1");
Patch(
_B2019;
LookUp(_B2019; PrimaryColumn = PrimaryColumn1);
{
PROVEEDOR: TextInput3.Text
}
) )

Note: The PrimaryColumn represents the primary column in your _B2019 data source, which could identify one record uniquely in your _B2019 data source.

 

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

 

More details about the ForAll function and RenameColumns function, please check the following article:

ForAll function

RenameColumns function

 

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

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Apps Community Call

Monthly Power Apps Community Call

Did you miss the call?? Check out the Power Apps Community Call here!

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (40,264)