Open InfoPath Design >> New >> SharePoint Form
Library >> Design form
Here is default user interface
Design complete form follows as
Drag and drop Textbox >> set properties for it
Drag and drop Dropdown List >> set properties for it
Drag and drop Date Picker >> set properties for it
Drag and drop Repeating Table
Set 3 columns
Drag and drop Textbox >> set properties for it
Drag and drop Textbox >> set properties for it (note:
data type: decimal)
How to create auto number repeating table:
Drag and drop Textbox >> right click >> choose
Change Control and then Calculated Value from the context menu that appears …
Reference more below
In InfoPath Designer 2010, create a new Blank Form template.
On the Home tab under the Controls group, click Repeating
Table and add a repeating table with 3 columns to the form template.
Right-click the first field (field1) in the repeating table
and choose Change Control and then Calculated Value from the context menu that
appears.
With the first field (field1) still selected, click the
Properties tab or double-click field1 to bring forward the Properties tab.
On the Properties tab under the Properties group, click
Default Value.
On the Field or Group Properties dialog box on the Data tab
under the Default Value section, click the formula button behind the Value text
box.
On the Insert Formula dialog box, select the Edit XPath
(advanced) check box.
On the Insert Formula dialog box, type the follow formula
into the Formula text box:
count(../preceding-sibling::*) + 1
On the Insert Formula dialog box, click Verify Formula to
ensure that the formula does not contain any errors. Click OK to close the
message box that says whether the formula contains or does not contain errors.
Correct any errors if necessary.
On the Insert Formula dialog box, click OK.
On the Field or Group Properties dialog box, ensure that the
Refresh value when formula is recalculated check box is selected, and then
click OK.
Finish !!!
Save the InfoPath form template and publish it for example
to a SharePoint form library.
Click ok
Save file
Input your site collection
Login to SharePoint site
Choose Form Library
Choose create a new form library
Input library name
Add 3 columns follow as
Add more column to display sum of time >> Add >>
HourCount, in Function choose sum
Click Next
Publish
Preview
Input data
Open SharePoint site
Input data in SharePoint form library, you can see No.1 auto
increase
Save form
Form is saved with sum HourCount.
Thanks.
0 comments:
Post a Comment