在XML SPY中打开XSD文件时出错 [英] Error on opening XSD file in XML SPY

查看:75
本文介绍了在XML SPY中打开XSD文件时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我有一个XSD文件,并尝试使用XML间谍程序打开该MasterFile.xsd并抛出错误,该错误是

包含/导入的模式文件"c:\ dir1 \ CodeCntr.xsd"具有不同的目标名称空间.

预期为"http://www.coderEx1.com/schemas/2011/07.sm"
找到"http://www.coderEx1.com/schemas/2004/06.sm"


在我的MasterFile.xsd中,我有一个声明为
的名称空间



I have an XSD file and tried to open that MasterFile.xsd using XML spy and it throws error that the

Included/imported schema file "c:\dir1\CodeCntr.xsd" has a different target namespace.

Expected "http://www.coderEx1.com/schemas/2011/07.sm"
Found "http://www.coderEx1.com/schemas/2004/06.sm"


In my MasterFile.xsd, I have a namespace declared

xmlns:grpz = "http://www.coderEx1.com/schemas/2011/07"


在CodeCntr.xsd中,我有


and in the CodeCntr.xsd I have

xmlns="http://www.coderEx1.com/schemas/2004/06"



我该如何解决?

谢谢
AB



how can I resolve this?

Thanks
AB

推荐答案

您真的需要具有不同名称空间的架构文档吗?不过有可能.

您需要正确引用启用了名称空间的架构,例如,参见:
http://www.w3schools.com/Schema/el_import.asp [ http://docstore.mik.ua/orelly/xml/xmlnut/ch16_03.htm [ ^ ].

—SA
Do you really need schema documents with different namespaces? It is possible though.

You need to reference a namespace-enabled schema properly, see, for example:
http://www.w3schools.com/Schema/el_import.asp[^],
http://docstore.mik.ua/orelly/xml/xmlnut/ch16_03.htm[^].

—SA


这篇关于在XML SPY中打开XSD文件时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆