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

Patch to a new excel worksheet each week

Hi, 

 

I'm looking to patch a set of running results from a browse gallery to a new excel sheet every week. 

 

I've managed to get the patch working to the same sheet but this obviously overides the results in there. I need to record and save results to a different sheet each week. 

 

Is this possible in powerapps? 

 

Any help would be greatly appreciated. 

 

Thanks,

Callum

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Patch to a new excel worksheet each week

Hi @CallumTR90,

CheckboxDemo.PNGIn Excel, assuming your table is named Table1, add a column to the table called Archived and make the type Number.  On your Gallery, add a checkbox control. Set the Text property of the checkbox control to ThisItem.Archived,  Make the OnCheck property of the checkbox:

Patch(Table1,ThisItem,{Archived:1})

. Filter the Gallery by setting its Items property to

Filter(Table1,Archived<>1)

Now, when you check the box, the record will disappear from the gallery.  It will still be saved in the spreadsheet but it will not be displayed in the gallery because of the filter.

You would use an Edit form to enter each new record.  It will be shown in the gallery until you check it off. 

4 REPLIES 4
Super User
Super User

Re: Patch to a new excel worksheet each week

Hi @CallumTR90,

You would need to remove the old datasource table and replace it with an identical blank table with the same name and fields. Wouldn’t it be easier to just add a column to archive the old records and filter on that column for records not archived?

CallumTR90
Level: Powered On

Re: Patch to a new excel worksheet each week

Hi @Drrickryp,

Thanks for your response.

Would the archiving be done in excel or PowerApps? If you wouldn’t mind briefly explaing how I’d do this, that would be a massive help.
Super User
Super User

Re: Patch to a new excel worksheet each week

Hi @CallumTR90,

CheckboxDemo.PNGIn Excel, assuming your table is named Table1, add a column to the table called Archived and make the type Number.  On your Gallery, add a checkbox control. Set the Text property of the checkbox control to ThisItem.Archived,  Make the OnCheck property of the checkbox:

Patch(Table1,ThisItem,{Archived:1})

. Filter the Gallery by setting its Items property to

Filter(Table1,Archived<>1)

Now, when you check the box, the record will disappear from the gallery.  It will still be saved in the spreadsheet but it will not be displayed in the gallery because of the filter.

You would use an Edit form to enter each new record.  It will be shown in the gallery until you check it off. 

Administrator
Administrator

Re: Patch to a new excel worksheet each week

Thanks for your help with this thread @Drrickryp!

 

@TopShelf-MSFT

Helpful resources

Announcements
firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

SecondImage

PowerApps Monthly Community Call

Next Wednesday, August 21st at 8am PDT

Top Community Contributors for July 2019

Top Community Contributors for July 2019

Let's thank our top community contributors

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

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

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

FifthImage

Dynamics 365 and Power Platform April 2019 Release notes

Features releasing from April 2019 through September 2019!

SixthImage

Power Summit Australia 2019

August 20-23rd 2019

Users Online
Currently online: 31 members 4,260 guests
Please welcome our newest community members: