Home > InfoPath2010, SharePoint 2010 > Customize SharePoint list using InfoPath2010 form Part2

Customize SharePoint list using InfoPath2010 form Part2

Customize SharePoint list using InfoPath2010 form Part1

Customize SharePoint list using InfoPath2010 form Part3

Customize SharePoint list using InfoPath2010 form Part4

In the last post, I have shown you how to customize SharePoint list using InfoPath , in this post I will continue where I left off to show you how to create different views for each form.(edit form and display form)

1. Go to Page Design view and click the New View called DisplayView

2. Create the form like shown below by first inserting a table and then drag the following fields to the table. However, as you can see that it displays input control like textbox and dropdown list. In the display view, we would like to show only the values of the fields rather than take input from the users. I will clean it up in the following steps.

3. Now, delete the input controls and drag a calculated value control from control sections in the home tab

4. Insert the calculated value by selecting the FX

5. Select each field from the fields selection.

6. After you have completed the above steps , you will see the view shown below.

7. Publish the new form and go to the employee list and click the Form Web Parts and select (Employee) Display Form

8. Edit the InfoPath form web part and select the DisplayView

9. Click save and open an item, you will see the display view shown below. However , you will notice that instead of displaying HR for Department Name it displays 2.This is because Department Name is a lookup field , you need to grab the value from the second data source in InfoPath. I will show you the steps next.

10. Right click the calculated field and select the Calculate Value Properties

11.Edit the formula by selecting the fx.

12.Delete the existing formula and click Insert Field or Group

13. Select the Show advanced view and change from Main to Department(Secondary) from the dropdown list.

14 Select the Title from the dataFields and then click Filter Data.

15. Select the Department Name from the Main Data source for the first field.

16. Select the ID from the Department(Secondary) data source.

17. Republish your form, you might get the following errors, just ignore it.

18. After the form is published, you can see the correct information on the form shown below



Comparing SharePoint List and Form Library Forms

SharePoint 2010 – Set default value for a lookup column using InfoPath and no code

  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: