What you describe is a normal diagnostic.
When the application is expecting the IFU ref table (IFU Schema selected) and I load the CC table instead, the error is detected, line number fits (2), but the message says:
e.Message = "The "CCReferenceTable" element is not declared."
When a validating parser using the IfuReferenceTable
schema ("IFU Schema selected", as you say) encounters a CCReferenceTable
element for which it has no definition, it will correctly complain as it did.
Think of it this way: When the parser sees CCReferenceTable
, it tries to lookup what it knows about CCReferenceTable
. When it cannot find anything about CCReferenceTable
, it lets you know with the above message.
Xerces-J would say it this way:
Cannot find the declaration of element 'CCReferenceTable'.
Perhaps this statement is a bit more clear.