编写XSD文件的问题 [英] Issues writing XSD file

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

问题描述

学习XML并需要一些帮助。

我有xml文件,我想为它创建一个xsd文件。

我写了我的文件,但是尝试验证xml到我的xsd时遇到错误。

任何指向正确方向的人都会感激。

XML文件:

Learning XML and need some help.
I have am xml file and I have want to create an xsd file for it.
I have written my file, but am experiencing errors when trying to validate the xml to my xsd.
Any pointing in the right direction you can give would be appreciated.

XML file:

展开 | 选择 | Wrap | 行号

推荐答案

您的架构形成不符合标准。请参阅此示例,了解在complexType中放置元素和属性的位置:
Your formation of schema doesn''t fit standards. See this example for where to place your elements and attributes within a complexType:
展开 | 选择 | Wrap | 行号


感谢您的回复。

这是我现在拥有的。

我的XSD文件:
Thanks for your reply.
Here is what I have now.
My XSD file:
展开 | 选择 | Wrap | 行号


你可能的意思是''xs:normalizedString''(一个规范化的)


你的from和msg节点实际上是一个复杂的元素包含其他元素。例如来自你代码的''from'':
You probably mean ''xs:normalizedString'' (one normalized)

Your from and msg nodes are actually a complex element containing other elements. eg ''from'' from your code:
展开 | 选择 | Wrap | 行号


这篇关于编写XSD文件的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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