当前位置:网站首页>C#远程调试
C#远程调试
2022-07-31 02:43:00 【故里2130】
在我们日常生活中,经常遇到本机电脑可以运行程序,但是别的电脑无法运行程序,很多情况下,都是环境变量导致的。我们可以使用远程调试,只需要复制代码过去,而不用安装对应的vs软件,这样比较节约时间。本环境是虚拟机和主机处于一个局域网中,使用vs2022。
1.在远程的电脑上,下载vs2022远程工具
下载 Visual Studio Tools - 免费安装 Windows、Mac、Linux
2.在远程的电脑上,安装

3.在远程的电脑上,启动
点击确定
并且记录下远程电脑的IP地址和端口号,后面要使用
4.在本机电脑上,创建一个winform程序

把Debug文件复制到远程的电脑上, 并且运行

5.在本机电脑上,选择附加到进程
6. 输入远程的IP地址和端口号,点击查找,进行连接
此时找到运行的软件,点击附加按钮
7.然后回到远程电脑上,点击软件上面的按钮,此时本机就会有断点进入了

同时,远程的电脑也会显示连接
拓展
对于其他使用vs开发的程序,例如网站或者c++程序等等,都可以使用此方法来进行远程调试。
边栏推荐
- mycat的主从关系 垂直分库 水平分表 以及mycat分片联表查询的配置详解(mysql5.7系列)
- 你们程序员为什么不靠自己的项目谋生?而必须为其他人打工?
- Brute Force/Adjacency Matrix Breadth First Directed Weighted Graph Undirected Weighted Graph
- The final exam first year course
- Calculate S=a+aa+…+aa…a
- MPPT solar charge controller data collection - through the gateway acquisition capacity battery SOC battery voltage, wi-fi
- CentOS7下mysql5.7.37的卸载【完美方案】
- There is a problem with the multiplayer-hlap package and the solution cannot be upgraded
- Problems that need to be solved by the tcp framework
- 10. Redis implements likes (Set) and obtains the total number of likes
猜你喜欢

Problems that need to be solved by the tcp framework

全流程调度——MySQL与Sqoop

STP选举(步骤+案列)详解

Coldfusion file read holes (CVE - 2010-2861)

Detailed explanation of STP election (step + case)

4、敏感词过滤(前缀树)

The simulation application of common mode inductance is here, full of dry goods for everyone

真正的CTO,是一个懂产品的技术人

Why is String immutable?

Intranet Infiltration - Privilege Escalation
随机推荐
try-catch中含return
Draw Your Cards
[1154] How to convert string to datetime
7、私信列表
The difference between link and @import
BAT can't sell "Medical Cloud": Hospitals flee, mountains stand, and there are rules
分布式与集群是什么 ? 区别是什么?
19. Support Vector Machines - Intuitive Understanding of Optimization Objectives and Large Spacing
AI在医疗影像设备全流程应用
Introduction and use of Drools WorkBench
User interaction + formatted output
SQL注入 Less46(order by后的注入+rand()布尔盲注)
Force buckled brush the stairs (7/30)
10. Redis implements likes (Set) and obtains the total number of likes
YOLOV5 study notes (3) - detailed explanation of network module
【shell基础】判断目录是否为空
基于opencv实现人脸检测
Unity3D Button 鼠标悬浮进入与鼠标悬浮退出按钮事件
Installation, start and stop of redis7 under Linux
SQL注入 Less54(限制次数的SQL注入+union注入)