方法在 Visual Studio 中有效,但在 exe 中无效 [英] Method works in Visual Studio but not from exe

查看:46
本文介绍了方法在 Visual Studio 中有效,但在 exe 中无效的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的应用程序有一个非常奇怪的问题.当我从 Visual Studio 调试应用程序时,它运行良好,但是当我从调试文件夹执行 exe 文件时,其中一种方法根本不起作用.

I have a really wierd problem with my app. When i debug the application from visual studio it works perfectly but when i execute the exe file from the debug folder one of the methods does not work at all.

奇怪的是,它只是一种方法,应用程序中的其他一切都可以工作

the weird thing is that it is just one method everything else in the application works

我阅读了类似类型的问题,大多数文章都针对配置管理器的方向,其中平台设置设置为anyCPU"我将平台更改为 x64,因为我的开发机器有 64 位操作系统,但我还是出现同样的问题..

i read up on similar types of problems and most articles go in the direction of the configuration manager where the setting for platform is set to 'anyCPU' i changed the platform to x64 because my development machine has a 64 bit OS but i still get the same problem occuring..

这个问题让我难倒了过去几个小时......

this problem has me stumped for the last couple hours....

任何帮助将不胜感激

谢谢

推荐答案

如果您正在使用 Web 服务,则可能会出现服务器响应缓慢的问题.在调试程序时运行速度较慢",答案有很多时间.没有调试程序运行速度很快,你会遇到在你需要的时候找不到答案的问题.

If you are working with webservices there could be the problem, that the answer from the server is to slow. while debugging the program "runs slower" and the answer has many time. Without debugging programm runs fast and you have the problem of the answer not beeing there when you need it.

我曾经遇到过这种问题,而且需要很长时间才能明白这一点;-)

I've had this kind of problem one time and too needed a long time to get the point ;-)

另一个解决方案可能是在 VisualStudio 内外设置不同的安全策略(我不太确定,但有时似乎程序在调试时拥有更多权限(至少在我的 PC 上)).

Another solution could be a different security police in and out of VisualStudio (I'm not really sure but sometimes it seems like Programs have more rights while debugging (at least on my PC)).

这篇关于方法在 Visual Studio 中有效,但在 exe 中无效的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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