Step 1: Read the XAML FileUse the Read Text File activity to read the XAML file into a variable called fileContent (type String).
Step 2: Load the XML ContentUse an Invoke Method activity to load the XML content into an XmlDocument.TargetObject: diagramTree (of type XmlDocument, initialized using New XmlDocument()).MethodName: LoadXmlParameters:Direction: InType: StringValue: fileContent
Step 3: Get the Names of All Activities Using XPathUse another Invoke Method activity to select nodes using XPath.TargetObject: diagramTreeMethodName: SelectNodesParameters:Direction: InType: StringValue: “ui:MessageBox” (XPath to get all activity elements regardless of namespace)Output: activityNodes (variable of type XmlNodeList)
The above code is only check if thd xaml has the messagebox activity or not. But i need to check all the activity of that xaml file which is using default Name. How to do that?