23-11-22 08:43 AM
23-11-22 11:12 AM
23-11-22 11:18 AM
23-11-22 11:55 AM
24-11-22 03:48 PM
24-11-22 04:23 PM
@Neeraj Kumar,
Thats correct. It needs those because it queries the BP database to collect the information.
I think you can get some of the information you're looking for using AutomateC. Just take a look through the available flags.
Cheers,
24-11-22 06:44 PM
try{
// Initialize variables for Process Dictionary & Direction
Dictionary<String, Object> dictProcess = new Dictionary<String, Object>();
string direction = "";
// Initialize String Builder Object & Prepare File Header
string delimiter = ",";
StringBuilder sb = new StringBuilder();
sb.Append("ACTION_NAME" + delimiter + "PARAMETER_NAME" + delimiter + "PARAMETER_TYPE" + delimiter + "PARAMETER_DIRECTION" + delimiter + "PARAMETER_DESCRIPTION" + "\r\n");
// Load Input XML Document Inside XDocument Object
XDocument xml = XDocument.Load(Input_File_Path);
// Fetch Process Name
String processName = xml.Element("process").Attribute("name").Value;
// Generate Process Dictionary
foreach (XElement element in xml.XPathSelectElements("process//subsheet"))
{
dictProcess.Add(element.Attribute("subsheetid").Value, element.XPathSelectElements("name").First().Value);
}
// Fetch Process Related Details
foreach (XElement element in xml.XPathSelectElements("process//stage"))
{
if (element.Attribute("name").Value.ToLower().Equals("start") || element.Attribute("name").Value.ToLower().Equals("end"))
{
foreach (XElement subElement in element.Descendants())
{
if (subElement.Name.ToString().ToLower().Equals("inputs") || subElement.Name.ToString().ToLower().Equals("outputs"))
{
foreach (XElement parameterElement in subElement.Descendants())
{
if (subElement.Name.ToString().ToLower().Equals("inputs"))
{
direction = "INPUT";
}
else
{
direction = "OUTPUT";
}
// Append Details Fetched For Current Action
sb.Append(dictProcess[element.XPathSelectElement("subsheetid").Value.ToString()] + delimiter + parameterElement.Attribute("name").Value + delimiter +
parameterElement.Attribute("type").Value + delimiter + direction + delimiter + parameterElement.Attribute("narrative").Value.Replace(",","|") + "\r\n");
// Write Process Details To Input CSV File
StreamWriter sw = new StreamWriter(Output_Folder_Path + @"\" + processName + ".csv");
sw.WriteLine(sb.ToString());
sw.Close();
}
}
}
}
}
Message = "The process/object details file got generated successfully";
Success = true;
}
catch (Exception ex)
{
Message = ex.Message;
Success = false;
}