visual-studio-2008

DLL and Main Project Building - Annoyance

I have a main executable project and a dll project in VS 2008. Sometimes when I clean/rebuild the dll and then clean/rebuild the main project, the main project will not build because it says the dll is in use. Closing both projects resolves the issue. Why does this occur and how do I prevent it from happening? It is annoying having t...

Using ClickOnce with dynamically loaded assemblies

In my application, I load some assemblies dynamically, depending on what was the user's choice. Naturally, these are not referenced in the project. When publishing with ClickOnce, these assemblies are not included in the package. The question is - is it possible to trick the ClickOnce publisher to use some other files not referenced in ...

How to move a subproject to a new folder in Visual Studio 2008 without breaking (ankhsvn) subversion revision history?

I have a c# solution with a bunch of projects. One of them resides in a folder that does not match the project name (for reasons I can't know since the guy who did it left before I arrived). My beloved ReSharper plugin goes all grumpy on me and draws blue swiggly lines under the namespace declarations and groans: "Namespace does not corr...

Best way to establish a connection for use with an ADO.NET command object

I'm designing a web service in ASP.NET and VS2008, and am using typed datasets for retrieving table data. These work well and establish their own connections through their associated TableAdapter objects. Edit: I'm using VB, BTW! I am now attempting to run a custom SQL string using a DataAdapter and a Command object, however I need to r...

Continuous Integration with 64-bit Sharepoint and TFS 2008?

I've set up a 64-bit TFS 2008 build server with Sharepoint, continuous integration and out-of-the-box MSTest. Unit tests for plain business logic classes run just fine and test results are published into TFS. However, any test that uses Sharepoint's API fails horribly, SPFarm.Local returning null and so on. Is there a way to fix this? T...

Missing color code in Visual studio 2008

Hi i am missing the color code of my web.config files in Visual studio 2008 SP1 how do i get it back you can se it here link text ...

How can I stop Visual Studio running all my web services

How to stop Visual Studio 2008 from automatically running my web services. I have a large Visual Studio 2008 solution that contains a number of web app projects and also several wcf web services. I have set the solution to have only one startup project, yet when I right-click on the web app project and select "Debug" > "Start New Insta...

Where do I store Visual Studio 2008 Report templates

I want to create a number of report templates for use with the report disigner (rdlc) in VS2008. I can find some guidance for VS2005 but none for 2008. I have tried replicatiing the 05 advice in 08 but to no avail. Pleasse help ...

Reflection - Iterate object's properties recursively within my own assemblies (Vb.Net/3.5)

Hi, I wonder if anyone can help me - I've not done much with reflection but understand the basic principles. What I'm trying to do: I'm in the process of developing a class that gathers a lot of information about the local system, network, etc... to be used for automated bug reporting. Instead of having to change my test harness every...

Release build fails with "The specified module could not be found" when using "Generate serialization assembly" set to "Auto" or "On".

Environment: Visual Studio 2008 Release build Generate serialization assembly "Auto" or "On" It fails with Error 1 The specified module could not be found. (Exception from HRESULT: 0x8007007E) C:\Path\Projects\Project\Project\ SGEN if I either use Debug build or set the serialization assembly to "Off" in the Release build t...

Debugging a 2D array in VS2008

I have a 2D array which contains height information. I want to see it in the debugger to a certain point if the values are correct. I know we can see a 1D array using "myArray,5", but it doesn't work when i write "myArray,5,5" or "myArray[0],5", without the quotation marks. Does anybody know how to do this? Or is this even possible? ...

Problem with solution and project with same name.

I have restored a solution from my previous, trashed Vista laptop to my newly installed XP laptop, both VS 2008 SP1. In a folder called Rhino, I have a solution called Rhino.sln, and a web site in a folder called Rhino. When I open the solution, VS only opens the project. Note that when I copied the root Rhino folder to my new machi...

Is it possible to automatically hook up events in C# using VS2008?

I recently switched over to C# from vb.NET and within visual studio found that hooking up events is extremely annoying. In VB I could select a control from a drop down on the top left and the event on the top right drop down and the method would automatically be created and attached to the control using "handles". I know that is not su...

c++ debugging in vis studio 2008, how to break when a variable becomes zero

I can detect when a variable changes, but it changes so often that its no use - what I want is to detect the moment that a variable becomes zero. Thanks, ...

How to list all the printers on the network?

I am trying to list all the printers on the network (we have a very large, cross-ocean network) using VS2008 & c#. I am looking to replicate the functionality of the Find Printers dialog box in Windows (which can be found by going to Printers and Faxes, clicking Add a printer, selecting Network Printer, then picking Find a printer in ...

Visual Studio 2008 Vista Socket Problem

Hey there, I am trying to use a port checking program written in Visual Studio 2008 using the 3.5 SP 1 .Net Framework, and I seem to have a problem using my program on Vista based OS's (in this case the actual OS is Windows 2008 Server (both 32 and 64 bit machines)) while it does however work fine on XP machines. I am not entirely sure w...

Checking Visual Studio files for code comments

I'm looking for a Visual Studio 2008 add-in or macro that will examine all of the .cs files and report back on "code comment coverage". Our company's standard is that all C# classes, methods, and properties are code commented. I've got a large solution, and going through the files by hand wastes a lot of time. If I had a report that t...

How to remove a tab attribute in ASP .NET AJAX Toolkit using Regular Expression

I have tried to remove the following tag generated by the AJAX Control toolkit. The scenario is our GUI team used the AJAX control toolkit to make the GUI but I need to move them to normal ASP .NET view tag using MultiView. I want to remove all the __designer: attributes Here is the code <asp:TextBox ID="a" runat="server" __designer:w...

wcf rest starter kit preview 2 error: requires VS 2008 SP1

Hi, I'm trying to install the WCF REST Starter Kit Preview 2, but that fails with the message that I need Visual Studio 2008 SP1, which I actually do have installed: Microsoft Visual Studio 2008 Version 9.0.21022.8 RTM Microsoft .NET Framework Version 3.5 SP1 Does anybody know what the problem is? Thanks, regards, Miel. ...

Turn off IIS 7.5 Attach security warning

IIS 7 and Visual Studio 2008, every time you attach to w3wp.exe you get an Attach Security Warning, How do you turn this of? It would be cool to know also, how to keep it attached for linger, as this seems to time out after a while Btw: I Added this as a comment to the answer below, the first thing i did was try the msdn article ht...