Hi Team,
I have SharePoint 2013 site. I have Nintex workflows and Forms activated on that site.
I want to check which list has Nintex form is created.
Suppose there are 6 list are there in site from that only 3 list has Nintex form created and others are normal list item insert.
How I can check this? Is there any class/property which help us to get form is created or not?
Below sample code works for Nintex workflows.
Code:
private static void DownloadAndScanNintexWFFiles(ConnectionConfig connectionConfig, string listTitle, List<WorkflowInfo> workflowsInfo, string webUrl)
{
XmlNode query = GetXmlNode(XElement.Parse("<Query><Where><Eq><FieldRef Name='File_x0020_Type' /><Value Type='Text'>xml</Value></Eq></Where></Query>"));
XmlNode viewFields = GetXmlNode(XElement.Parse("<ViewFields></ViewFields>"));
string rowLimit = "4000";
XmlNode queryOptions = GetXmlNode(XElement.Parse("<QueryOptions><ViewAttributes Scope='Recursive' /></QueryOptions>"));
string webId = String.Empty;
XmlNodeList nintexItems = ListsServiceHelper.GetListItems(connectionConfig, webUrl, listTitle, String.Empty, query, viewFields, rowLimit, queryOptions, webId);
foreach (XmlNode nintexItem in nintexItems)
{
XmlAttribute workflowId = nintexItem.Attributest"ows_NintexWorkflowID"];
if (workflowId == null)
continue;
Guid ows_NintexWorkflowID = Guid.Parse(workflowId.Value);
WorkflowInfo existingWF = workflowsInfo.Where(x => x.BaseID == ows_NintexWorkflowID).SingleOrDefault();
if (existingWF != null)
existingWF.WorkflowTechnology = WorkflowTechnology.Nintex;
}
}
Thanks,
Harish Patil