Monday 18 March 2013

Print Feature in the InfoPath in SharePoint Library

Problem: - User wants to print the InfoPath Form through browser in the SharePoint.
For example, user has created one list or library and opened the document including all data for print purpose without cuts off any data.

Solution: - Out of the box InfoPath print functionality is only present in SharePoint Library not in SharePoint List. For list we need some customization in the InfoPath code behind.

Example with SharePoint Library:-
According to user requirement, take one form library for print functionality. Following are the steps to configure the “Print Functionality”.
1. Take one InfoPath Form with two views, “Main View” for entering all the data and “Print View” for only displaying all the data.

2. Main view is very simple to create by just drag-drop the controls but Print view takes “Calculated Value” control for binding the existing fields like textbox, rich text box etc. in print view.

3. InfoPath under File > Info > Form Options you have several possibilities to restrict users from doing stuff with your form. To get the print functionality you need to enable the InfoPath Ribbon ("Show InfoPath commands in Ribbon or toolbar" and also the Print Preview option”)

4. Publish the InfoPath Form in SharePoint Library, then open the items and click the “print view” in the top menu bar.















No comments:

Post a Comment