# XML error: Fatal error encountered during schema scan

**URL:** <https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703>\
**Category:** Incorporation\
**Created:** [January 24, 2022, 9:30am UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703 "2022-01-24T09:30:30Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![dan\_perry](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/d/4da419/32.png) [@dan\_perry](https://xmlforum.companieshouse.gov.uk/u/dan_perry)\
**Post date:** [January 24, 2022, 9:30am UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/1 "2022-01-24T09:30:30Z")

</div>

Hello,

I have been trying to send an XML request to the test XML gateway to test company formation. When I send my XML data over, the response is `XML failed schema validation: XML error: Fatal error encountered during schema scan line 16 column 155`. I am unsure where line 16 is referring to, as I reformatted my XML request to all be on a single line, and yet the same error is returned. What is the XML Gateway referring to by line 16?

Any help would be greatly appreciated.

---

<div class="post-metadata">

**Author:** ![snicholas](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/snicholas/32/81_2.png) [@snicholas](https://xmlforum.companieshouse.gov.uk/u/snicholas)\
**Post date:** [January 24, 2022, 1:32pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/2 "2022-01-24T13:32:13Z")

</div>

Hi Dan,

I would suggest you running your file through a commercial application called XML spy as this will format it for you.

Please let me know if this works for you.

SDN

---

<div class="post-metadata">

**Author:** ![pekatete1](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/pekatete1/32/146_2.png) [@pekatete1](https://xmlforum.companieshouse.gov.uk/u/pekatete1)\
**Post date:** [January 24, 2022, 3:46pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/3 "2022-01-24T15:46:07Z")

</div>

Could also open the file as is using Notepadd++ where you can look for line number and position (displayed in the status bar)

---

<div class="post-metadata">

**Author:** ![dan\_perry](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/d/4da419/32.png) [@dan\_perry](https://xmlforum.companieshouse.gov.uk/u/dan_perry)\
**Post date:** [January 24, 2022, 4:13pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/4 "2022-01-24T16:13:15Z")

</div>

As I said in my original post, it does not matter how the file is formatted when I send it, the error always says line 16 column 155. It gives me that line number even if I put all the XML data onto one line.

---

<div class="post-metadata">

**Author:** ![pekatete1](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/pekatete1/32/146_2.png) [@pekatete1](https://xmlforum.companieshouse.gov.uk/u/pekatete1)\
**Post date:** [January 24, 2022, 6:02pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/5 "2022-01-24T18:02:11Z")

</div>

Try opening the file in a browser - does that still NOT show line numbers?  
Saying that, I think you have a syntax error (or a character that’s not utf8 encoded) in your file, in which case, format the file using an xml formatter and if that does not highlight the error re-upload the (newly formatted) file and it should give you the ‘proper’ line number. Last but not least, upload the file here.

---

<div class="post-metadata">

**Author:** ![dan\_perry](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/d/4da419/32.png) [@dan\_perry](https://xmlforum.companieshouse.gov.uk/u/dan_perry)\
**Post date:** [January 25, 2022, 12:23pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/6 "2022-01-25T12:23:33Z")

</div>

Hi,

XML Spy isn’t the best solution for us. firstly because of the high cost to obtain a license, but also because the company I work for does not use Windows. I have run my XML file through the syntax checker in the Eclipse IDE. After a couple of changes, it lists no syntax errors when comparing my file to the schemas provided by CH. However when I send this fixed file through the XML Gateway as before, I still get line 16 column 155 as the source of an error. In my file, line 16 contains the hashed authentication value as seen here: (I have replaced my hashed auth value with Xs for security, but it still contains 32 characters). ` <Value>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</Value>`

If there was a problem in the element on line 16, surely I would get an authentication error returned by the gateway instead?

---

<div class="post-metadata">

**Author:** ![snicholas](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/snicholas/32/81_2.png) [@snicholas](https://xmlforum.companieshouse.gov.uk/u/snicholas)\
**Post date:** [January 25, 2022, 1:03pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/7 "2022-01-25T13:03:54Z")

</div>

Hi Dan,

Can you please post your test submission data and test presenter ID to [xml@companieshouse.gov.uk](mailto:xml@companieshouse.gov.uk) and I will take a look at it.

SDN

---

<div class="post-metadata">

**Author:** ![dsalami](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/d/96bed5/32.png) [@dsalami](https://xmlforum.companieshouse.gov.uk/u/dsalami)\
**Post date:** [February 19, 2023, 3:56pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/8 "2023-02-19T15:56:35Z")

</div>

hi @dan_perry @snicholas how was this issue resolved. I’m getting the exact issue "line 16 column 155 " in the error response… I’m simply testing with postman using thee sample request here . [http://xmlgw.companieshouse.gov.uk/examples/companydetails\_req.xml](http://xmlgw.companieshouse.gov.uk/examples/companydetails_req.xml). I put in my test credentials .

---

<div class="post-metadata">

**Author:** ![snicholas](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/snicholas/32/81_2.png) [@snicholas](https://xmlforum.companieshouse.gov.uk/u/snicholas)\
**Post date:** [February 20, 2023, 7:41am UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/9 "2023-02-20T07:41:27Z")

</div>

I have just sent you an email.

Best if we set up a new test account for you, as the one you have is very old, and a lot has changed since yours was opened.

SDN

---

<div class="post-metadata">

**Author:** ![user32](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/u/43a26b/32.png) [@user32](https://xmlforum.companieshouse.gov.uk/u/user32)\
**Post date:** [May 12, 2025, 7:13pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/10 "2025-05-12T19:13:28Z")

</div>

Hello I am also getting same error no matter what format i send the request  
tried MD5(SenderID + Password + TransactionID) lot of permutations and combinations still not sure what is the problem. I have signed up for the testing account. any help would be great. thanks.

---

<div class="post-metadata">

**Author:** ![snicholas](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/snicholas/32/81_2.png) [@snicholas](https://xmlforum.companieshouse.gov.uk/u/snicholas)\
**Post date:** [May 16, 2025, 3:06pm UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/11 "2025-05-16T15:06:20Z")

</div>

Hi,

Are you developing XML input (filing) or XML output (name checks / data / images) please?

SDN

---

<div class="post-metadata">

**Author:** ![shivam](https://xmlforum.companieshouse.gov.uk/letter_avatar_proxy/v4/letter/s/ce73a5/32.png) [@shivam](https://xmlforum.companieshouse.gov.uk/u/shivam)\
**Post date:** [June 4, 2025, 8:32am UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/12 "2025-06-04T08:32:21Z")

</div>

Hiya, I’m running into this too now. Does anyone have the solution?

---

<div class="post-metadata">

**Author:** ![snicholas](https://xmlforum.companieshouse.gov.uk/user_avatar/xmlforum.companieshouse.gov.uk/snicholas/32/81_2.png) [@snicholas](https://xmlforum.companieshouse.gov.uk/u/snicholas)\
**Post date:** [June 10, 2025, 8:34am UTC](https://xmlforum.companieshouse.gov.uk/t/xml-error-fatal-error-encountered-during-schema-scan/703/13 "2025-06-10T08:34:34Z")

</div>

Hi,

What are you developing? XML input (filing) or XML output (name checks / data / images) please?

SDN
