[英]How do I pass command line from a WPF application to another application?
[英]How do I pass two namespaces into XSDObjectGen from command line?
我正在嘗試將XSDObjectGen用作Visual Studio 2008中的PreBuild。
我可以在命令行上運行它:
XSDObjectGen\XSDObjectGen.exe AnalyticsDomainModel.xsd /l:cs /d /p /n:AdaptorAnalyticDomainModel.Primatives /n:AdaptorAnalyticDomainModel /f:AnalyticDomainModel
然后,這提示我鍵入兩個名稱空間:
Imported namespaces were found. Please enter valid .NET namespace names for each namespace. WARNING. Namespaces chosen must not conflict with types and element names from the schemas. Xsd namespace = http://sempra.com/schema/adm/primatives/1.0. Please enter a CLR namespace name for this namespace: AdaptorDomainModel.Primatives Xsd namespace = http://sempra.com/schema/adm/1.0. Please enter a CLR namespace name for this namespace: AdaptorDomainModel Done. Success Writing file AdaptorDomainModel.cs. Writing file AdaptorDomainModel.Primatives.cs.
我必須在“命名空間:”之后輸入位。 因為它要求我手動輸入名稱空間,所以無法自動執行該過程。
如何在命令行中傳遞兩個參數? 這是錯誤嗎?
我找到了答案。...也許您會遇到同樣的問題,並希望找到解決方案。 就是這樣
此工具的更高版本上有一個選項/ y,您可以這樣使用它:
XSDObjectGen\XSDObjectGen.exe AnalyticsDomainModel.xsd /l:cs /d /p /n:dummy /y:"AdaptorAnalyticDomainModel.Primatives|AdaptorAnalyticDomainModel"
這允許傳遞額外的名稱空間名稱。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.