How Can We Help?

Search for answers or browse about Sintel Forms.

Programmatically creating Sintel Forms

You are here:

It is possible to create a form within a list that uses Sintel Forms without using the Sintel Forms Viewer.

You may for example need to programmatically or automatically create forms based on data from a third party application or data source and this can be automated using another workflow tool such as SharePoint Designer or Power Automate as long as you do it in the correct way.

In the Sintel Forms Viewer when you click on the standard “Save” button or click on one of the actions buttons from the “Actions” menu a number of things happen.

#1 A new list item is created containing the data that was entered into the form

#2 The new list item is updated to store the workflow status (SintelFormsStatus) & workflow id (SintelFormsStatusId) -this occurs if you have enabled the workflow features of Sintel Forms

#3 A folder is created within the workflow history list related to the main list (SintelFormsWorkflow_<id_of_the_list>)

#4 One or more items are added into the workflow history list linked to the list item from step 1 above

 

If you intend to programmatically create forms in a list you must ensure that the process you use to accomplish this completes the 4 steps above to ensure that the resulting form is created correctly and it’s workflow history is generated correctly.

 

How to do it

#1 Create the list item in main list

Use whatever tool or process you like to create the list item (SharePoint Designer, Power Automate etc…)

 

#2 Set the workflow columns for the list item in the main list

These are SintelFormsStatus and SintelFormsStatusId and these need to be initialized with following values:

  • Name of the status (e.g. “Draft”) should be placed in the SintelFormsStatus column
  • Id of the status (which is a GUID) should be placed in the SintelFormsStatusId column.

You can figure out the GUID by looking at other list items in a list holding the same status, or you can look it up in the SintelFormsSettingsv2 table that holds configuration options for every form in a Site (ids of statuses can be found in the Statuses column).

Sintel Forms Workflow Columns

Sintel Forms Workflow Columns

 

#3 Create items in the workflow history table

Each list handled by Sintel Forms has its corresponding workflow history table, named SintelFormsWorkflow_<id_of_the_list>.

  1. You need to create a folder whose name matches the ID of the list item and within it you need to create an entry for each status progression and action that is executed on a form
  2. ListItemId field needs to point to the list item to whom you want to link the workflow history to
  3. You must set either the StatusId or TaskId field to the id of a status or action.
Sintel Forms Workflow History

Sintel Forms Workflow History

 

If you want to initialise an item with a initial workflow status you would have to create a single entry in that table, with StatusId value set.
Was this article helpful?
0 out of 5 stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Please submit the reason for your vote so that we can improve the article.
Table of Contents