How to add dynamique element on existing XML file

Hello guys,
Please i want write in the end of xml file , like image
I’m using a loop to extract dynamique book name then I have to write it inside.
Thank you in advance,
Kindely regards,

@ifranity
is this to write into a new empty XML file or is it to append / insert within an existing XML file?

In first case you can do it on text base e.g. with String Lists.
In second case we would use the available XML API from .Net

Let us know the details and we will help you on finalizing the case

1 Like

Hello,
Thank you for the reply,
It’s to insert into an existing xml file,
First I start to modify existing xml value
Xdoc.root.element(“authorname”).value = name
Xdoc.root.element(“authorcity”).value = city
And I have deficulties to write the book element below.
Kindly regards,

@ifranity
Can you please share the sample xml. On this base we will help you on working aout a solution thanks

@ppr
please find attach the xml file.

I need to add book element with booknames before the end element tag “Authors”

thank you File.xml (95 Bytes)

Kindely regards,

@ifranity
Find Starter Help here:
ifranity.xaml (8.4 KB)

dont miss out to rewire the path to xml for readin and saving

1 Like

thank you, it’s the wishes output :wink: :+1: :+1:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.