I want to get all the child element name along with their parent element name from XML.
My XML like in below,
I want the tag name like below
Is possible to get the tag name like above? Please provide me the solution if Possible.
It is easy to get the element name and the attribute of that element @Iswarya.G. But to check if the element has child or not, you need to check for each element. Then if it has child, then you need to deserialize the xml again and the process continues. Please try it on your own. Will try to provide you a sample workflow
@HareeshMR I tried lot of ways. But, I can’t. Please provide me the sample workflow.
Your question is technicaly coupled with performance concerns, given by available options and APIs. However we cannot push barriers when we dont try to do unusual things.
Here is a first preview on my RnD:
let me do some checks and I will share later the XAML with you
the main Idea was about:
- getting all elements with RootElement.Descendents
- Iterating over all elements and constructing the path by using the Name with Element.Name and the Parents with Element.Parent
Lets see at your end on how performant the Bot will be. For big XML Data I would guess that the BOT will go up on execution time.
Demo XAM here: Iswarya.xaml (8.7 KB)