使用Visual Studio在计算机上运行项目,在没有Visual Studio的计算机上运行项目。 [英] Running a project on a machine with Visual Studio and on a machine without Visual Studio.

查看:124
本文介绍了使用Visual Studio在计算机上运行项目,在没有Visual Studio的计算机上运行项目。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我刚遇到组织中的情况如下。



我有一个C#WinForms项目,它测量项目API的一些性能读数。然后,我有一台机器,我必须在其上进行性能测量。



我有两种方法来执行任务:

1)在安装了Visual Studio的计算机上。

2)在未安装Visual Studio的计算机上。



我已经编译了项目,等等,我将从bin \debug文件夹中的EXE文件运行程序。



在我看来,两者的性能测量值都不会有差异。上述环境只要Visual Studio实例(devenv.exe)没有在机器上运行。



请注意这个场景。



你认为即使Visual Studio实例(devenv.exe)没有在系统中运行,winforms程序也会报告较慢的性能读数吗?



注意:我更喜欢安装VS,因为它有助于调试一些代码错误。



我真的很喜欢寻找 一些紧急帮助。

Hi,

I just came across a situation in my organization which is as follows.

I have a C# WinForms project that measure some performance readings of our project APIs. Then, I have a machine on which I have to take performance measurements.

I have 2 ways to perform the task:
1) On a machine where Visual Studio is installed.
2) On a machine where Visual Studio is not installed.

I have already compiled the project, and so, I will be running the program from EXE file in bin\debug folder.

In my thinking, the performance measurements will not differ in both of the above environments as long as Visual Studio instance (devenv.exe) is not running in the machine.

Please throw some light on this scenario.

Do you think that even when Visual Studio instance (devenv.exe) is not running in the system, the winforms program will report slower performance readings ?

Note: I prefer having VS installed because it helps debug some code errors some times.

I am really looking for some URGENT help.

推荐答案

您应该只使用Visual Studio来开发和测试您的应用程序。一旦您对它正常工作感到满意,您应该创建代码的Release版本并使用它来运行性能测试。只要安装了正确版本的.NET框架,就可以在任何机器上执行此操作,无论是否安装了Visual Studio。
You should only use Visual Studio to develop and test your application. Once you are satisfied that it is working correctly, you should create a Release version of the code and use that to run your performance tests. You can do this on any machine whether Visual Studio is installed or not, as long as the correct version of the .NET framework has been installed.


Hi Vivek,



我的理解如下所示,纠正我如果我错了



您想要衡量项目API的性能读数通过你的C#Winforms应用程序,



现在你处于两难境地,无论是使用Visual Studio Debugging进行测试还是直接从Debug文件夹运行它,



解决方案 -



从Visual Studio运行任何应用程序时,它会运行到调试模式,以使调试成为可能,应用程序也包含调试所需的资源,这可能会导致Winforms应用程序运行速度变慢。



而不是直接从调试文件夹中检查它以及何时想要在调试模式下运行,从Visual Studio运行它。



问候,

Ravi
Hi Vivek,

What I understood is as below scenario, correct me If I am wrong

you want to measure performance reading of your project API through your C# Winforms application,

now you are in dilemma whether to test it using Visual Studio Debugging or run it directly from Debug folder,

Solution -

while you run any application from Visual Studio, it runs into Debug mode, to make debugging possible the application also contains necessary resources for debugging, which may cause the Winforms application run a bit slower.

instead you can check it directly from Debug Folder and when you want to run in Debug mode, run it from the Visual Studio.

Regards,
Ravi


我写这篇文章一年多了。为此道歉。



我之前写的成功开发了我的项目。

事实证明,我需要在不运行Visual Studio的情况下运行项目。将它安装在机器上对性能没有影响。



感谢您的回复。
I am writing this more than an year after. Apologies for that.

I developed my project successfully as I wrote before.
As it turned out, I needed to run the project without running the Visual Studio. Having it installed on the machine had no effect on the performance.

Thanks for the replies.


这篇关于使用Visual Studio在计算机上运行项目,在没有Visual Studio的计算机上运行项目。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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