Search This Blog

Monday, June 20, 2011

Pre-Populating a Repeating Table in InfoPath 2010

Scenario:  Client wants their users to be able to add and delete choices from a table.   The number of choices will vary from form to form.  So this calls for a repeating table.   But how can I pre-populate the form in a way that the users can delete the pre-filled data if it's not needed?

I searched and search the Google-sphere for this one.  The closest I came was this solution for InfoPath 2007 from    S.Y.M. Wong-A-Ton

InfoPath 2010 does things a bit differently, but that blog helped along the way:

 1.  Add a repeating table to your form.




 2.  In the fields section, right click on the field and change the property to "Repeating".


 3.  On the form, right click on the field and "Change Control" to "repeating table".

Now we have a nested repeating table.  

 4.  Right click on the outermost table.
 5.  Click on "Repeating Table Properties"
 6.  Click "Edit Default Values".


 7.  Right Click on the repeating field.
 
 8.  Click on "Add another (field name) below.
 9.  Repeat step 8 until all the fields to be pre-populated are created.  


10.  Click on the 2nd field created.  Fill in the desired value.


11.   Repeat until all values are added
NOTE:  Leave the first  field empty.  
Completing this field will pre-populate any new fields to be added.
12.  Click ok.
13.  Click "Customized Commands"
14.  Optional:   Deselect all actions and click ok.

NOTE:  This will prevent the users form adding new columns multiple ways.

15.  Deselect the "Show Insert button and hint text" command.

NOTE:  This will remove the "Add New Item" from the outermost repeating table. 
Failure to do this step will enable users to add multiple versions of the innermost table.


What it looks like:

NOTE:  I configured my  "Customized Commands" so that my users can only remove these items.
 Any questions??

Friday, April 29, 2011

BASPUG Quick Tip Perils of the Title column

 Strategies with the Title Column
Appropriate for SharePoint 2007 or 2010
I presented this quick tip at the January BASPUG meeting in Cambridge MA.
The Title column is an OOB SharePoint field that provides what it says:  a title for a list item.  The name of the column can be changed and it can provide a nice pull-down menu with access to view, edit, delete the meta data.  The title column is great for a simple summarization of the information contained in the entry.

The negatives of using the column are many:
1.  Automatic naming of an item is difficult (not impossible:  work flows and InfoPath tricks)
2.  Using the title column precludes the use of this field to filter data using a SharePoint List Filter Web Part.
3.  Using this field for look up columns may cause confusion.
4.  Sometimes clients want the title to be a multiple line field:  not possible with the title field.

I suggest thinking about the need for the title column  in your SharePoint solution.

How to remove the Title Column is a Popular Question 

1.  Undo the "require" column setting 

2.  Hide the column by turning on content management and choose hide (column must not be required at the column level)
 
3.  In the default view, choose the "edit" option  (This will allow the users to edit the meta data.)


     

    Thursday, April 7, 2011

    Welcome

    Welcome to my SharePoint blog.  I hope to share my trials and tribulations using SharePoint and InfoPath along with the many associated tools of the trade.