visual-studio

How to work offline with TFS

Hi Our TFS server has some temporary connectivity issues right now, and as such VS has gone unresponsive, leaving 50+ developers unable to work! Is it possible to switch TFS into an offline mode in the event of such an issue? Martin ...

Visual C++ Runtime Library Linker Woes

Observe this close Scenario even though it appears to be the same as my previous questions. Still I am not getting an answer. So please don't report as a duplicate. I have a project which has 10 dependencies. First I compiled using the /MTD option in the C/C++ codegeneration section in the main project and all its dependencies are getti...

VisualStudio: no debug output

Hi, I'm trying to debug a C# application. The method: System.Diagnostics.Debug.WriteLine("something"); should do the work, but in the Output window (set to "debug" and with all the options activated) I can't see a single line I'm trying to write. Any idea? Thanks EDIT: I'm using VS2008 ...

Project file with just files and no built output

How can I make a project file (VS 2008) that just has some data files in and has no built output? I can make an empty project and add my data files to it (which get copied to the output folder ), but it produces an EmptyProject.dll after I do a build. I want just my data files in the output directory and not some empty DLL or EXE. I wa...

Include and Reference Resource File from C# class

I have an image that is used in some PDF files that my C# application generates. I know how to reference the image file when it is located in my workspace, but when I compile the program, I don't see the image anywhere in the compiled directory. Can someone tell me what happened to that file, or do I have to manually package the file al...

What is the .cs file under MyDataContext.dbml for?

What is that individual (currently empty) file under MyDataContext.dbml for? Directory structure: Mydatacontext.dbml MyDataContext.cs MyDataContext.dbml.layout MyDataContext.designer.cs ...

Non-Default Constructor

I have a component I created in C# which had previously been using the default constructor, but now I would like it to have its parent form create the object (in the designer), by passing a reference to itself. In other words, instead of the following in the designer.cs: this.componentInstance = new MyControls.MyComponent(); ...

Why is /clr incompatible with /mt and /mtd in Visual Studio?

Hi can anybody please explain for me how and why /clr is incompatible with /mtd ? What is the alternative for this? What happens internally if I use /md or /mdd ? As far as I know we don't combinedly use /clr and /mtd. Can someone explain if there is a way to do this? And please explain me how and why /clr is incompatible with /mt and ...

Ways to deploying console applications in C#

Hello. I have a relatively complex console application which relies on several dlls. I would like to "ship" this in the best form. My preferred way would be an exe file with all dependencies embedded in it (not that big, about 800K). Another thing would be to just zip the contents of the "Debug" folder and make that available, but I'm no...

What is the Visual Studio shell (standalone shell) good for?

Is it some sort of pre-built GUI scaffolding? Why would I Want it instead of a WinForms UI, which is quick to set up? What does it give me that I would have to spend time writing? Do I get floating windows and docking, like in Visual Studio 2008? Is there a money-cost to using it? What does the deployment look like - is my app a standal...

Visual Studio builds my project with several unused files and libraries

For a while now I have had visual studio producing builds that have all sorts of extra files in them. I have checked everything that I know of for where these could be coming from and I am out of ideas. For example I was previously using MbUnit but now I use nunit. None of my projects even reference MbUnit but it is still appearing in...

how do I stop a C++ application during execution to debug into a dll?

Hi all, I have an application for which I do not have the code, and a dll for which I do have the code. I need to be able to debug into the dll, but lacking the source for the exe, how do I do this? The dll code is mfc c++; I believe that the main app is the same thing as well. I've tried doing a 'set target application' deal, where ...

VWD 2008 Adding reference to a public class

Problems started after upgrading from VWD2005 to VWD2008. In VWD2008 the App_Code does not exist any more. How can i add a reference to a class that existed in the App_Code directory of VWD2005? ...

Syntax highlighting for domain-specific language in VS2008?

Hello. I have a domain-specific language with a certain syntax. Is it possible to make Visual Studio 2008 recognize custom languages in the usual editors? That is, associate a given file extension to a certain syntax-coloring scheme? If so, would you have any pointers as to how to do this? I'm sorry if this is a duplicate. I searched bu...

How do I hide Visual Studio Add-in disabled commands

I created a Visual Studio Add-in that adds additional commands (four of them) to the top of Code Window context menu. I'm using permanent UI approach. Depending on the cursor position within code only one of the commands would be visible and thus selectable. Other three would be hidden. I set supported and enabled status within QuerySta...

Visual Studio crashes when debug tests are run with the Test Result view in another screen

When I try to run unit tests, in debug mode only, on "Microsoft Visual Studio Team System 2008 SP1" and the Test Results view is open in a screen other than the main one (I have 2 monitors), the devenv.exe process crashes. Have you ever encountered a similar error? Have you found a workaround for it? ...

Launch single console application

Possible duplicate: Run single instance of an application using Mutex I am using VS 2008 in C# on a console application. Not sure if there is any class available (process?) to limit only single console application running at a time. ...

Visual Studio: Cycling through breakpoints

Is there a shortcut to cycle through my breakpoints? I often lose track of the breakpoints when debugging a project. When I finish working with one bug, I have to reset my breakpoints for a new bug that I am about to solve. It would be handy to have a keystroke that would allow me to cycle through the breakpoints and disable ones I don't...

Conditional breakpoint when debugging XSLT in Visual Studio

I found out that you can debug XSLT in Visual Studio, which is pretty cool, but how do you set a conditional breakpoint? For example, how would I break only if a certain variable is empty? ...

Connect to a running instance of Visual Studio 2003 using COM, build and read output

For Visual Studio 6.0, I can connect to a running instance like: o = GetActiveObject("MSDev.Application") What prog ID do I use for Visual Studio 2003? How do I execute a 'Build Solution' once I have the COM object that references the VS2003 instance? How do I get the string contents of the build output window after executing the bui...