VS C# 应用程序批量构建

发布于 2024-11-25 18:20:51 字数 2731 浏览 1 评论 0原文

当我在VS2008中使用批处理构建时,我可以在其输出窗口中看到csc.exe批处理命令语句。 然后我将该字符串复制到解决方案主目录中的 CMD 中 它有效但保持沉默。没有错误,没有警告,只是“Microsoft 保留所有权利”,并且不生成 exe 模块。

怎么了?怎么了?

C:\SatServer>c:\WINDOWS\Microsoft.NET\Framework\v3.5\Csc.exe /noconfig /nowarn:1701,1702 /platform:x 86 /errorreport:提示 /warn:4 /define:DEBUG;TRACE /reference:bin\Debug\CommonClass.dll /reference:b 在\Debug\DBManager.dll /reference:bin\Debug\Microsoft.Data.ConnectionUI.Dialog.dll /reference:bin\De bug\Microsoft.Data.ConnectionUI.dll /reference:bin\Debug\State.dll /reference:c:\WINDOWS\Microsoft.N ET\Framework\v2.0.50727\System.configuration.dll /reference:"C:\Program Files\Reference Assemblies\M icrosoft\Framework\v3.5\System.Core.dll" /reference:"C:\Program Files\Reference Assemblies\Microsoft \Framework\v3.5\System.Data.DataSetExtensions.dll" /reference:c:\WINDOWS\Microsoft.NET\Framework\v2。 0.50727\System.Data.dll /引用:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Deployment.d ll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll /reference:c:\WINDOWS\Microso ft.NET\Framework\v2.0.50727\System.Drawing.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50 727\System.Management.dll /引用:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Windows.Fo rms.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /reference:"C:\Progr am Files\Reference Assemblies\Microsoft\Framework\v3.5\System.Xml.Linq.dll" /debug+ /debug:full /fil ealign:512 /optimize- /out:obj\Debug\SatServer.exe /resource:obj\Debug\SatServer.Cli.resources /reso urce:obj\Debug\SatServer.ServerForm.resources /资源:obj\Debug\SatServer.Properties.Resources.res 来源 /resource:SQLCommands_Old_SelectExamQuestions.sql,SatServer.SQLCommands._Old_SelectExamQuest ions.sql /资源:SQLCommands\InsertExam.sql,SatServer.SQLCommands.InsertExam.sql /资源:SQLComm ands\InsertExamQuestionListDetails.sql,SatServer.SQLCommands.InsertExamQuestionListDetails.sql /reso urce:SQLCommands\InsertExamQuestionList.sql,SatServer.SQLCommands.InsertExamQuestionList.sql /资源 ce:SQLCommands\GetExamId.sql,SatServer.SQLCommands.GetExamId.sql /资源:SQLCommands\GetExamQuesti onListId.sql,SatServer.SQLCommands.GetExamQuestionListId.sql /资源:SQLCommands\SelectExamQuestio ns.sql,SatServer.SQLCommands.SelectExamQuestions.sql /资源:Activation\Activation.exe,SatServer.A ctivation.Activation.exe /target:winexe /win32icon:ikey.ico Cli.cs Cli.Designer.cs LOCALCLASSBOX\Leg al.cs LOCALCLASSBOX\LocalBox.cs ServerCommunicator.cs ServerForm.cs ServerForm.Designer.cs Program.c Properties\AssemblyInfo.cs Properties\Resources.Designer.cs Properties\Settings.Designer.cs

结果: Microsoft 编译器(R) Visual C# 2008 版本 3.5.30729.1 适用于 Microsoft (R) .NET Framework 版本 3.5 (C) 微软公司。保留所有权利

When I use batch build in VS2008, I can see in its output window the csc.exe batch command statement.
Then I copy that string into CMD inside the Solution main directory
It works but keeps silent. No errors no warning, just "Microsoft All rights reserved", and no exe module is generated.

What's the matter? what's wrong?

C:\SatServer>c:\WINDOWS\Microsoft.NET\Framework\v3.5\Csc.exe /noconfig /nowarn:1701,1702 /platform:x
86 /errorreport:prompt /warn:4 /define:DEBUG;TRACE /reference:bin\Debug\CommonClass.dll /reference:b
in\Debug\DBManager.dll /reference:bin\Debug\Microsoft.Data.ConnectionUI.Dialog.dll /reference:bin\De
bug\Microsoft.Data.ConnectionUI.dll /reference:bin\Debug\State.dll /reference:c:\WINDOWS\Microsoft.N
ET\Framework\v2.0.50727\System.configuration.dll /reference:"C:\Program Files\Reference Assemblies\M
icrosoft\Framework\v3.5\System.Core.dll" /reference:"C:\Program Files\Reference Assemblies\Microsoft
\Framework\v3.5\System.Data.DataSetExtensions.dll" /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.
0.50727\System.Data.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Deployment.d
ll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.dll /reference:c:\WINDOWS\Microso
ft.NET\Framework\v2.0.50727\System.Drawing.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50
727\System.Management.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Windows.Fo
rms.dll /reference:c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /reference:"C:\Progr
am Files\Reference Assemblies\Microsoft\Framework\v3.5\System.Xml.Linq.dll" /debug+ /debug:full /fil
ealign:512 /optimize- /out:obj\Debug\SatServer.exe /resource:obj\Debug\SatServer.Cli.resources /reso
urce:obj\Debug\SatServer.ServerForm.resources /resource:obj\Debug\SatServer.Properties.Resources.res
ources /resource:SQLCommands_Old_SelectExamQuestions.sql,SatServer.SQLCommands._Old_SelectExamQuest
ions.sql /resource:SQLCommands\InsertExam.sql,SatServer.SQLCommands.InsertExam.sql /resource:SQLComm
ands\InsertExamQuestionListDetails.sql,SatServer.SQLCommands.InsertExamQuestionListDetails.sql /reso
urce:SQLCommands\InsertExamQuestionList.sql,SatServer.SQLCommands.InsertExamQuestionList.sql /resour
ce:SQLCommands\GetExamId.sql,SatServer.SQLCommands.GetExamId.sql /resource:SQLCommands\GetExamQuesti
onListId.sql,SatServer.SQLCommands.GetExamQuestionListId.sql /resource:SQLCommands\SelectExamQuestio
ns.sql,SatServer.SQLCommands.SelectExamQuestions.sql /resource:Activation\Activation.exe,SatServer.A
ctivation.Activation.exe /target:winexe /win32icon:ikey.ico Cli.cs Cli.Designer.cs LOCALCLASSBOX\Leg
al.cs LOCALCLASSBOX\LocalBox.cs ServerCommunicator.cs ServerForm.cs ServerForm.Designer.cs Program.c
s Properties\AssemblyInfo.cs Properties\Resources.Designer.cs Properties\Settings.Designer.cs

result:
Microsoft Compiler(R) Visual C# 2008 version 3.5.30729.1
for Microsoft (R) .NET Framework version 3.5
(C) Microsoft Corp.. All rights reserved

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文