My listitems are opened via an infopath form. Client wants a second aspx form to open the listitems.
(the infopath form only shows a subset of the fields but the aspx form shows all fields).
When opening the aspx form, sharepoint redirects me to the infopath form. Somewhere, a redirect was taking place.
After a lot experimenting, I found that not only do you need hide the original List Form Web Part but you also need to set the ControlMode to Display. Here are the 2 lines of code that need to be modified in the original List Form Web Part:
Change:
<ControlMode xmlns=”http://schemas.microsoft.com/WebPart/v2/ListForm”>Edit</ControlMode>
To:
<ControlMode xmlns=”http://schemas.microsoft.com/WebPart/v2/ListForm”>Display</ControlMode>
Change:
<IsVisible>true</IsVisible>
To:
<IsVisible>false</IsVisible>
No comments:
Post a Comment