cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

Web link version doesn’t work for For All and Patch

I am not sure why but for some reason when I play the app , the save all button ( using "for all" and "patch") works perfectly but it doesn’t work when I click on the web link of the same app. Please see screenshot below with my formula. 

 

VS325_0-1600302910646.png

Ideally, how it works is it is saving multiple records using "Save All" button, but the gallery should be clear/reset once I hit the save button. It works perfectly fine when I hit the "play" button from PowerApps but there are issues when I use the web link version of the same app. I would like to clear all the records/reset the gallery once I hit my SaveAll button. 

 

 @WarrenBelz - Please help. I see that you've been very helpful to other people in the community. 

 

11 REPLIES 11
Highlighted
Regular Visitor

Re: Web link version doesn’t work for For All and Patch

Please help someone! I’m really struggling here

Highlighted
Super User
Super User

Re: Web link version doesn’t work for For All and Patch

@VS325 ,

What exactly are you trying to do with WeekendDate?

Highlighted
Regular Visitor

Re: Web link version doesn’t work for For All and Patch

I’m using my “Day” column to determine my weekend date . For example- if data entry for day is 9/16 , then this formula I have for weekend date gives me Saturday’s date (9/19) in this case. 

Highlighted
Super User
Super User

Re: Web link version doesn’t work for For All and Patch

@VS325 ,

What exactly happens when you run if off the link? Also does it play properly when you run it from "my Apps?"

Highlighted
Regular Visitor

Re: Web link version doesn’t work for For All and Patch

Yes it works perfectly when running it on the app, but the web link version is the problem. My formula for "Save All" button is - 

 

UpdateContext({LetsEdit: 0});
ForAll(
Newformgallery_2.AllItems,
Patch(
ODM_Productivity,
Defaults(ODM_Productivity),
{AccessionNumber: 'AccNo.TextInput'.Text},
{PrimarySite: PrimarySiteTextInput.Text},
{Reason: Reasoncombobox.Selected.Result},
{ProjectDescription: ProjectDescComboBox.Selected.Result},
{Day: ReviewDateDataCardValue.SelectedDate},
{MRN: MRNTextInput.Text},
{Classofcase: ClassOfCaseTextInput.Text},
{Comments: Commentstextbox.Text},
{SubmittedBy: User().FullName},
{SupervisorEmail: HRJob_2.Selected.SupervisorEmail},
{SubmittedByEmail: User().Email},
{Status: "Pending"},
{Hour: HoursTextInput.Text},
{
WeekEndDate: ReviewDateDataCardValue.SelectedDate + 7 - Weekday(
ReviewDateDataCardValue.SelectedDate,
Sunday
)
},
{LastUpdated: Now()},
{LastUpdatedBy: User().FullName},
{Volume: 1},
{ProjectNumber: ProjectNumberDataCardValue.Text}
)
);

I edit the records in the gallery using the "edit button". My gallery has some combo boxes and mostly text inputs, Project description and review date are populated from the form above, so that user doesn't have to manually enter a project and its pre-populated using a form. 

 

Screenshot 1

VS325_0-1600340701985.png

 

The for all and patch function in the "Save All" button is used to save multiple records. On clicking "Save All" button in my app version, the gallery is reset automatically. Save all enables to get rid of all the records once saved so that user can't double-click and double save it. I see a blank screen again with only default values for review date and project description selected from the form above. 

 

VS325_1-1600341830460.png

Now using the web link of the same version and see the difference. Hitting "Save All" button doesn't reset the gallery. I would like the gallery to reset like it does in the app version. The record just stays there in the web link version. 

PA.png

 

Thanks for your help in advance. 

Highlighted
Super User
Super User

Re: Web link version doesn’t work for For All and Patch

@VS325 ,

So the only issue in the "web link" version is the resetting of the gallery? 
I cannot see anything in your code that "resets" the gallery - what are the Items of the Gallery?

Highlighted
Regular Visitor

Re: Web link version doesn’t work for For All and Patch

Yes exactly. Resetting gallery is an issue in the web link. I have tried Reset (My gallery) function on select of "save all" which doesn't help. 

Highlighted
Super User
Super User

Re: Web link version doesn’t work for For All and Patch

@VS325 ,

The gallery "reset" depends on the Items as mentioned - what are they?

I will be offline now due to timezone - will pick up your response in the morning.

Highlighted
Regular Visitor

Re: Web link version doesn’t work for For All and Patch

In my case, I want to reset all individual controls in my gallery example- project description, accession number, reason, hours etc. Resetting them individually like Reset (Project description) doesn't work because my controls are in the gallery and I want to handle resetting on select of "Save All" button outside the gallery. 

 

VS325_0-1600358979179.png

 

Helpful resources

Announcements
secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

August 2020 CYST Challenge

Check out the winners of the recent 'Can You Solve These?' community challenge!

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Users online (4,237)