visual-studio-2010

Running NUnit tests in Visual Studio 2010 with code coverage

不打扰是莪最后的温柔 提交于 2020-01-22 05:34:34
问题 We have recently upgraded from Visual Studio 2008 to Visual Studio 2010. As part of our code base, we have a very large set of NUnit tests. We would like to be able to run these unit tests within Visual Studio, but with code coverage enabled . We have ReSharper, so can run the tests within Visual Studio, but it does not allow the code coverage tool to do its thing and generate the coverage statistics. Is there any way to make this work, or will we have to convert the tests over to MSTest?

Data type mismatch in criteria expression. MS Access VB

夙愿已清 提交于 2020-01-22 03:14:47
问题 ' OK button Private Sub OK_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK.Click Dim con As New OleDbConnection("Provider=Microsoft.jet.oledb.4.0;data source=C:\Users\Jill\Desktop\saddbase\Sadsystem\Sadsystem\bin\Debug\tenant.mdb") Dim cmd As OleDbCommand = New OleDbCommand("SELECT * FROM info WHERE TN_ID = '" & UsernameTextBox.Text & "' AND Password = '" & PasswordTextBox.Text & "' ", con) con.Open() Dim sdr As OleDbDataReader = cmd.ExecuteReader() ' If the

Data type mismatch in criteria expression. MS Access VB

China☆狼群 提交于 2020-01-22 03:14:39
问题 ' OK button Private Sub OK_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK.Click Dim con As New OleDbConnection("Provider=Microsoft.jet.oledb.4.0;data source=C:\Users\Jill\Desktop\saddbase\Sadsystem\Sadsystem\bin\Debug\tenant.mdb") Dim cmd As OleDbCommand = New OleDbCommand("SELECT * FROM info WHERE TN_ID = '" & UsernameTextBox.Text & "' AND Password = '" & PasswordTextBox.Text & "' ", con) con.Open() Dim sdr As OleDbDataReader = cmd.ExecuteReader() ' If the

after writing the code to add a toolbar to a dialog-based mfc the dialog doesn't run

让人想犯罪 __ 提交于 2020-01-22 02:36:09
问题 here's the code that I have used to create a toolbar on my dialog and I am in the early stages of the tutorial just added these codes to my program: InitialJobProject2Dlg.h CToolBar m_FirstToolBar; InitialJobProject2.cpp BOOL CInitialJobProject2Dlg::OnInitDialog() { CDialogEx::OnInitDialog(); // Add "About..." menu item to system menu. // IDM_ABOUTBOX must be in the system command range. ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX); ASSERT(IDM_ABOUTBOX < 0xF000); CMenu* pSysMenu =

VS 2010: Prevent display of Build Summary in the output window

落花浮王杯 提交于 2020-01-21 11:54:05
问题 In Visual Studio 2008 when you build in 'quiet' mode the build output window looks something like this: Compile complete -- 0 errors, 0 warnings ------ Build started: Project: JLTA.JBS.UI.Office.VSTODocument, Configuration: Debug Any CPU ------ ------ Build started: Project: JLTA.JBS.UI.Office.VSTOWorkbook, Configuration: Debug Any CPU ------ ------ Build started: Project: JLTA.JBS.UI.GeneralLedgerUpdater, Configuration: Debug Any CPU ------ Compile complete -- 0 errors, 0 warnings ==========

Viewing dynamically alloocated null-terminated strings with Visual Studio's debugger

回眸只為那壹抹淺笑 提交于 2020-01-21 08:16:46
问题 Is there any way to change the default behavior of Visual Studio's debugger such that when hovering over a null-terminated, dynamically allocated character array (C++), it will display the full content of the string, rather than the first character only? I should mention that I am using Visual Studio 2010. If there is a way to achieve this in VS2012 only though, I would be interested to know that as well! 回答1: There's a useful link for visual studio, C++ Debugger Tips: To interpret a pointer

“Exception has been thrown by the target of an invocation.” when building a Visual Studio 2010 VSPackage

柔情痞子 提交于 2020-01-21 07:42:46
问题 I recently create a couple of VSPackages for some Visual Studio extensions (menu bar/command). I compiled them correctly yesterday, checked into TFS (i'm the only one touching this project, FYI). I had already installed these extensions and were working fine. Today it doesn't compile! I get the following error: Exception has been thrown by the target of an invocation. This doesn't tell me anything, so i fired up Visual Studio with the following command: devenv.exe /Rebuild > out.log In my out

“Exception has been thrown by the target of an invocation.” when building a Visual Studio 2010 VSPackage

扶醉桌前 提交于 2020-01-21 07:42:05
问题 I recently create a couple of VSPackages for some Visual Studio extensions (menu bar/command). I compiled them correctly yesterday, checked into TFS (i'm the only one touching this project, FYI). I had already installed these extensions and were working fine. Today it doesn't compile! I get the following error: Exception has been thrown by the target of an invocation. This doesn't tell me anything, so i fired up Visual Studio with the following command: devenv.exe /Rebuild > out.log In my out

Convert Winform App to Console app

£可爱£侵袭症+ 提交于 2020-01-21 06:49:26
问题 Is there a quick and dirty way (or a VS Macro) to convert a WinForms app to a Console App? I have a number of these apps that are no longer needed as Winforms apps. I suppose I could create a bunch of new projects and copy paste modules and classes over, but if it's just a matter of removing the single form that I have and editing/deleting a few things, I'd rather do that. 回答1: You can change the project settings to create a Console Application instead of a Windows Application (just hit Ctrl

Where is WIN32 defined, and how can I include this definition in my project?

大憨熊 提交于 2020-01-21 06:32:30
问题 I am including a third party header and source file into my project. At the top of the header there is this: #if defined(WIN32) || defined(WIN16) #ifndef MSDOS #define MSDOS #endif #endif #include <stdio.h> #include <stdlib.h> #ifndef MSDOS #include <unistd.h> #endif #include "des.h" The problem is that #if defined(WIN32) fails and the compilation fails when trying to #include unistd.h which I don't want to do. I have third party project that works with this header file i.e. WIN32 is defined