visual-studio-2010

How to draw the bitmap icon on title bar when Windows Aero theme is enabled

☆樱花仙子☆ 提交于 2019-12-31 02:56:11
问题 I'm developing a MFC application ( DWM library is not available ). I want to draw a bitmap functioning as a button on the title bar. However, the bitmap won't present when the Aero theme is enabled in Windows 7 (There are no problem when I disable the Aero theme). But my application still reactable by clicking on the position of the bitmap. Does anyone can teach me how to solve this problem? Thanks 回答1: Drawing custom data into the frame area with DWM is described on MSDN, also the hit

F12 finds all references, not go to definition

做~自己de王妃 提交于 2019-12-31 02:54:26
问题 Lately my F12 key does not seem to be working as expected in Visual Studio 2010 Professional SP1. It should go to the definition of what is selected, but instead it's performing the find all references task - Ctrl+K, R. Does anyone have any ideas how I can fix this? It is getting quite annoying as I routinely use this shortcut - I am working on a large solution where it sometimes locks visual studio briefly trying to find all references. I have tried going to Tools -> Options -> Enviroment ->

C# -->Go to Definition ==> VB.NET

时光总嘲笑我的痴心妄想 提交于 2019-12-31 02:46:26
问题 I have a solution in VS 2010. There are two DLL projects: one UserControl in C# WPF (myCSharpUC) and other - WinForm UserControl in VB.NET (myVbUC) Actually in myCSharpUC I have an instance of myVbUC: myCSharpUC { private MyVbUC vbControl; ... somemethod() { vbControl.MyProperty } } Is there a way to "navigate to definition" of MyProperty directly? ( actually only metadata is displayed ) 回答1: It's a known issue, the workaround are two: use ctrl+, or use some plugin that add this function,

Shell commands in VB

烂漫一生 提交于 2019-12-31 02:44:28
问题 For some reason it seems that ampersands are not working like they should when I attempt to use them in shell commands in VB. When I attempt to link two commands together on the same line using an ampersand i receive the error: "filenotfoundexception was unhandled file not found" The command I am trying to run is: Shell("cd " & TextBox2.Text.ToString & " & adb -s " & TextBox15.Text.ToString & " shell monkey -p " & TextBox1.Text.ToString & " -v 1", AppWinStyle.Hide) I tried breaking it down to

Accessing the runtime library property in visual studio 2010

孤者浪人 提交于 2019-12-31 02:31:21
问题 This is basically a follow up question to: Using Visual Studio project properties effectively for multiple projects and configurations Our library's target name is currently in this format: $(ProjectName)-$(PlatformToolset)-$(PlatformShortName)-$(Configuration) We'd like to add information about the runtime library used by the project to the target name, I tried adding $(RuntimeLibrary) , but that doesn't seem to be set. Is there any other way to get the runtime library at the time the target

Namespace not recognized in C++/CLI

懵懂的女人 提交于 2019-12-31 02:10:51
问题 I asked this question recently: create a namespace in c++/cli? and so I am trying to create my own namespace in c++/cli. But when I use the same namespace in two separate files (.cpp), the namespace is clearly not recognized as being the same because I get errors when I try to reference the other class in the other file. Here's basically what I have: Pets.cpp: namespace Animals { public ref class Pets { public: List<Dog> ^vDogs; Pets::Pets() { vDogs = gcnew List<Dog^>(); } void Pets:

Visual Basic Command Line Compiler has stopped working

不打扰是莪最后的温柔 提交于 2019-12-31 01:57:28
问题 Yesterday, I could work with Visual Studio 2010 without any problem. However, today after I turned on the computer and tried to open my project (Web application with Visual Basic.NET) on VS2010 again, I got a message box showing as below: Later, I found out after I tried deleting suo file that this message box will show up whenever I open some file in Visual Studio so I tried to run the application. Then, I found another message box popped up as below: And after I close the message box, I

Visual Studio - Cannot build a simple project more than once

我的未来我决定 提交于 2019-12-31 01:56:10
问题 When I try to build a project twice in successon, i get the following error Error 2 Unable to copy file "obj\x86\Release\iFileUploader.exe" to "bin\Release\iFileUploader.exe". The process cannot access the file 'bin\Release\iFileUploader.exe' because it is being used by another process. If I close Visual Studio and reopen it, I can compile it again but only once. I have my projects hosted on a Windows network share. The server runs Windows 2008 R2 and Im on a Windows 7 machine and Ive tried

When debugging a console app, Visual Studio gets stuck in an exception-reporting loop. Why?

为君一笑 提交于 2019-12-31 01:47:10
问题 Consider this simple console application: using System; namespace Demo { class Program { static void Main(string[] args) { throw new Exception(); } } } I run this under the debugger in either Visual Studio 2010 or Visual Studio 2012 Beta. When I do so, naturally the debugger stops at the exception. Ok so far. But when I press F5 to continue (or choose Debug|Continue) it stops at the same exception again. I have to stop debugging for the program to exit. I expected the program to exit when I

Don't see Clean solution option in Visual Studio

柔情痞子 提交于 2019-12-31 01:40:28
问题 For one of the solutions, I don't see the Clean Solution option neither in the context menu when I right click on the solution name in the Solution Explorer nor in the Build menu. When I make any changes to the project and debug, VS never hits the break point and I get the "The breakpoint will not currently be hit. The source code is different from the original version." message. My understanding is that I need to clean the solution. For other solutions, I do see the Clean solution and I don