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

SharePoint List is not loading the correct customized form

I have these customized forms in a SharePoint List:

 

CreateIssueForm (NewForm)

EditAvvikelseForm (EditForm)

EditReklamationForm (EditForm)

EditTillbudForm (EditForm)

EditForbattringForm (EditForm)

ViewAvvikelseForm (ViewForm)

ViewReklamationForm (ViewForm)

ViewTillbudForm (ViewForm)

ViewForbattringForm (ViewForm)

 

The SharePointIntegration:

 

OnNew:

 

 

Refresh(Ärenden);
Set(
SharePointFormMode,
"CreateIssue"
);
NewForm(CreateIssueForm);
Navigate('CreateIssueScreen')

 

 

 

OnEdit:

 

 

Refresh(Ärenden);
Switch(
SharePointIntegration.Selected.Innehållstyp.Name,
"Avvikelse",
Set(
SharePointFormMode,
"EditAvvikelse"
);
EditForm(EditAvvikelseForm);
Navigate(EditAvvikelseScreen),
"Reklamation",
Set(
SharePointFormMode,
"EditReklamation"
);
EditForm(EditReklamationForm);
Navigate(EditReklamationScreen),
"Tillbud och olycksfall",
Set(
SharePointFormMode,
"EditTillbud"
);
EditForm(EditTillbudForm);
Navigate(EditTillbudScreen),
"Förbättringsförslag",
Set(
SharePointFormMode,
"EditForbattring"
);
EditForm(EditForbattringForm);
Navigate(EditForbattringScreen)
)

 

 

 

OnView:

 

 

Refresh(Ärenden);
Switch(
SharePointIntegration.Selected.Innehållstyp.Name,
"Avvikelse",
Set(
SharePointFormMode,
"EditAvvikelse"
);
ViewForm(ViewAvvikelseForm);
Navigate(ViewAvvikelseScreen),
"Reklamation",
Set(
SharePointFormMode,
"EditReklamation"
);
ViewForm(ViewReklamationForm);
Navigate(ViewReklamationScreen),
"Tillbud och olycksfall",
Set(
SharePointFormMode,
"EditTillbud"
);
ViewForm(ViewTillbudForm);
Navigate(ViewTillbudScreen),
"Förbättringsförslag",
Set(
SharePointFormMode,
"EditForbattring"
);
ViewForm(ViewForbattringForm);
Navigate(ViewForbattringScreen)
)

 

 

 

OnCancel:

 

 

Refresh(Ärenden);
Switch(
SharePointFormMode,
"EditAvvikelse",
ResetForm(EditAvvikelseForm),
"EditReklamation",
ResetForm(EditReklamationForm),
"EditTillbud",
ResetForm(EditTillbudForm),
"EditForbattring",
ResetForm(EditForbattringForm)
)

 

 

 

The issue, steps to recreate:

  1. Reload the SharePoint List (page)
  2. Select an item
  3. Click Edit
  4. The NewForm is opened! It should open EditForm!
  5. Close the form
  6. Reselect an item
  7. Click Edit
  8. The EditForm is opened.

I cannot wrap my head around why this is happening, hope someone can help!

 

 

3 REPLIES 3
WarrenBelz
Super User
Super User

Hi @Maggan ,

A word of advice - these integrated forms are not designed to do what you are doing, particularly the actions on the inbuilt buttons. I have seen many posts of them not delivering what is expected. I suggest you consider a standalone canvas app - it will work much better.

They were envisaged as a single-screen mechanism to edit/view the selected record or create a new one. 

Hi @WarrenBelz ,

 

What do you mean? My forms are simply New/Edit/View-forms. Why would it not be supported to create/edit/view items through them? The OnNew should open the NewForm and the OnEdit should open the EditForm etc, right? If this doesn´t work, why would Microsoft even bother with creating a possibility for customizing forms? A standalone app is not an option, because it is important to be able to choose an item from the list. 

Hi @Maggan ,

Sorry I missed your response.

Firstly, I am a user like you, so cannot speak on behalf of MS, however I have seen numerous posts (and have experienced it myself) of those in-built controls being modified and not producing the desired results. It seems the more complex the modification, the more likely of something not working. Also the more screens you make seems to affect it.

I have a number of reasonably complex integrated forms, but I only use the inbuilt buttons for the initial screen, which does the "standard" job of viewing/editing the selected SharePoint record. I then use buttons on the forms to send the users to other screens/functions and do what they need to do - I basically treat the rest like a standalone app (and it works fine).

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (1,217)