Hello Mat

 找回密码
 立即注册
查看: 571|回复: 0

c#中process的操作【MSbuild生成DLL】

[复制链接]

1300

主题

1526

帖子

114

金钱

管理员

Rank: 9Rank: 9Rank: 9

积分
22661
发表于 2023-7-4 10:30:13 | 显示全部楼层 |阅读模式
【1】CMD用法:https://blog.csdn.net/weixin_44548405/article/details/126470653
【2】(1条消息) 从零开始构建MSBuild C#项目文件_fhuan123的博客-CSDN博客
【3】CMD用法:(1条消息) MSBuild 强在功能 (C#调用 命令行工具)_weixin_30530339的博客-CSDN博客
【4】编译路径说明:c# - 第一次使用msbuild - IT工具网 (coder.work)
MSBuild my.csproj /p:OutputPath=bin\Debug\
MSBuild my.csproj /p:Configuration=Release /p: Platform=x86

  1.            string CSharpProj = newProjPath + @"/" + DLLName + ".sln";
  2.             //
  3.             string MSBuildStr = System.Windows.Forms.Application.StartupPath + @"/" + "Bin" + @"/" + "MSBuild.exe";
  4.             //string MSBuildStr = @"D:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin" + @"/" + "MSBuild.exe";
  5.             string MSBuildDebug = "Release";
  6.             string MSBuildPlatform = "x64";
  7.             //string cmdStr = MSBuildStr + " " + CSharpProj + " " + "-p:Configuration = " + MSBuildDebug + " " + "-p:Platform = " + MSBuildPlatform;
  8.             string cmdStr = MSBuildStr + " " + CSharpProj + " " + "/t:Rebuild /p:Configuration = " + MSBuildDebug + " " + "/p:Platform = " + MSBuildPlatform;
复制代码






算法QQ  3283892722
群智能算法链接http://halcom.cn/forum.php?mod=forumdisplay&fid=73
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Python|Opencv|MATLAB|Halcom.cn ( 蜀ICP备16027072号 )

GMT+8, 2024-5-24 02:08 , Processed in 0.197495 second(s), 22 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表