Page 1 of 1

Another XML question!

PostPosted: Tue Jun 20, 2023 4:32 am
by Ashbi
Sorry if this doesn't belong here,

next question about XML processing :?

My workflow has to read in hundreds of XML files. In another thread I had the question how to check which XML nodes exits or not and handle with it. Thanks again to @takbb for supporting me.

Now my workflow ist running but - bang - the XML Reader Node chrashs because the content of the XML file is corrupt. If I open th XML file e.g. with Notepad++ the content look like mess

Maybe you can guess my question :wink: How can I handle this error in my workflow while the workflow reads the XML file?

Thanks!

Re: Another XML question!

PostPosted: Mon Oct 16, 2023 10:52 am
by Fuchsia tude
Sounds like that's a problem with whichever app you're using to generate that XML. It's not a reading problem--as you say, Notepad++ shows the content as gibberish--it's properly reading bad content. The problem is that the XML is not being created properly in the first place.

Re: Another XML question!

PostPosted: Thu Jun 27, 2024 11:37 pm
by waderatke
Ashbi wrote:Sorry if this doesn't belong here,

next question about XML processing :?

My workflow has to read in hundreds of XML files. In another thread I had the question how to check which XML nodes exits or not and handle with it. Thanks again to @takbb for supporting me.

Now my workflow ist running but - bang - the XML Reader Node chrashs because the content of the XML file is corrupt. If I open th XML file e.g. with Notepad++ the content look like mess

Maybe you can guess my question :wink: How can I handle this error in my workflow while the workflow reads the XML file?

Thanks!

The majority of workflow platforms let you set up different nodes' error handling. Create a "Try-Catch" block surrounding the node of the XML reader.
The "Catch" block will be activated in the event that the parsing fails (due to corrupt data), enabling you to handle the problem graciously.

Re: Another XML question!

PostPosted: Mon Nov 04, 2024 11:56 pm
by Thomas Wright
By creating a "Try-Catch" block around the XML reader node, you can configure error handling for separate nodes. If the parsing fails (due to faulty data), the "Catch" block will be activated, allowing you to gracefully manage the issue.