XSD命名空间到C#命名空间 [英] XSD Namespace to C# Namespace

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

问题描述

我们正在寻找一种方法,使C#从XSD自动生成类并使用XSD中的名称空间信息创建C#名称空间.

We are looking for a way to have C# autogenerate classes from an XSD and create C# namespaces using the namespace info in the XSD.

似乎无法从XSD创建结构化(xxxx.yyyy.zzzz)C#命名空间吗?

Doesnt seem like you can create a structured (xxxx.yyyy.zzzz) C# namespace from the XSD?

我们有没有一个窍门吗?

Is there a trick we're missing?

谢谢

推荐答案

这可以解决这个问题吗? /n允许您指定用于将生成的类放入其中的名称空间.

Would this do the trick? the /n allows you to specify a namespace to put the generated class in.

xsd.exe /classes MyXSDInput.xsd /n:MyCsharpNamespace

这篇关于XSD命名空间到C#命名空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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