visual-studio

Resources for building a Visual Studio plug-in?

Hi, I'd like to build a pretty simple plug-in for Visual Studio, but I don't really know how this has to be done. Is this doable in (non-managed) C++? I'd like to know what resources you'd recommend me... Thanks. ...

How do I get the Click Once Publish version to match the AssemblyInfo.cs File Version.

Every time I publish the Application in Click Once I get get it to update the revision number by one. Is there any way to get this change automatically to change the version number in AssemblyInfo.cs file (all our error reporting looks at the Assembly Version). ...

Default smart device project can't find dependencies.

When running the default c++ project in Visual Studios for a Windows CE 5.0 device, I get an error complaining about missing resources. Depends says that my executable needs ayghsell.dll (the Windows Mobile shell), and CoreDll.dll. Does this mean that my executable can only be run on Windows Mobile devices, instead of any generic Windo...

How to find the current name of the test being executing?

I know I can figure out the name of the method as its being executed, just wondering if there is a way from the setup method. I guess an attribute method would work but from the setup method it would be the best. EDIT NUnit ...

How do I force unix (LF) line endings in Visual Studio (Express) 2008?

Is there a way to always have LF line endings in Visual Studio? I can never seem to find it! ...

Visual studio 2005 closes slowly

I experience that on several different machines, with plugins, without plugins, with VB.net or c# solutions of many different sizes, closing the solution in VS 2005 generally takes significantly more time than actually building the solution. This has always been the case for me since I started using visual studio 2005 so I have learned...

How do you force Visual Studio to regenerate the .designer files for aspx/ascx files?

Sometimes when I'm editing page or control the .designer files stop being updated with the new controls I'm putting on the page. I'm not sure what's causing this to happen, but I'm wondering if there's any way of forcing Visual Studio to regenerate the .designer file. I'm using Visual Studio 2008 EDIT: Sorry I should have noted I've a...

SQL file encoding in Visual Studio

When we create stored procedures in Visual Studio (with the extension .sql) the file encoding is automatically set to 'Unicode (UTF-8 with signature) - Codepage 65001'. This causes ours DBA's problems as their scripts don't like it. We have to manually go in and change them to 'Western European (windows) - Codepage 1252'. This only se...

How to get browser IP or hostname?

I have a web application that should behave differently for internal users than external ones. The web application is available over the Internet, and therefore obviously to the internal users as well. All the users are anonymous, not authenticated, but the page should render differently for internal users than external. What I'm doing ...

Syntax highlighting for html markup disappears in Visual Studio 2008

This happened to me in Visual Studio 2008 pre and post 2008 sp1 on more than one computer and to someone else I know, so it can't be an isolated incident. Seemingly random, every so often I lose all syntax highlighting in my aspx page (the html) so that Visual Studio now looks like a really expensive version of notepad. Does anyone kno...

Common Files in Visual Studio Solution

Many times I have seen Visual Studio solutions which have multiple projects that share source files. These common source files are usually out in a common directory and in the solution explorer their icon shows up with a link arrow in the bottom left. However, any time I try to add a source file to the project that is outside of that p...

Visual Studio Add-in not going away

Ok, so I demo'd Refactor Pro and Resharper, I'm more comfortable with Resharper so that's what I bought. When I uninstalled Refactor Pro I thought everything was breezy. However, now when I open Visual Studio I get The Add-in 'DevExpress Tools' failed to load or caused and exception, woudl you like to remove this Add in? If you choos...

Code Profiling in Visual Studio 2005

I have a Visual Studio 2005 Solution workspace which in turn has 8 projects included in it. I want to profile the complete code(all the projects) and get some measure about the absolute cycles taken by each function to execute, or at least percentage cycle consumptions. I checked out help for VS 2005, and also the project setiings optio...

Tips and tricks for working with Microsoft Visual Studio solutions and project

After answering on this question I thought it would be nice to collect some tips & tricks for working with MSVS solutions and projects. Here is my list: How to avoid saving new projects automatically to reduce garbage in file system. Uncheck Tools->Options->Projects and Solutions->Save new projects when created How to add common ...

How to change "Generate Method Stub" to throw NotImplementedException in VS?

How can I change default Generate Method Stub behavior in Visaul Studio to generate method with body throw new NotImplementedException(); instead of throw new Exception("The method or operation is not implemented."); ...

Upgrading To Visual Studio 2008 From 2005

What are some advantages available in Visual Studio 2008 that I can bring up to my boss so I can convince him to upgrade from 2005? My main goal is to use MVC, but I need some good reasons why this would be better than what we have now. ...

Can Visual Studio put timestamps in the build log?

In the build log I'd like to the start and end time of each project's compilation. Is there any way to get VS to do this? ...

"Cannot change DataType of a column once it has data" error in Visual Studio 2005 DataSet Designer

I've got a DataSet in VisualStudio 2005. I need to change the datatype of a column in one of the datatables from System.Int32 to System.Decimal. When I try to change the datatype in the DataSet Designer I receive the following error: "Property value is not valid. Cannot change DataType of a column once it has data." From my understa...

What is the shortcut key for Run to cursor

What is the shortcut key for Run to cursor in visual studio 2008? ...

What are the most useful (custom) code snippets for C#?

What are the best code snippets for C#? (using visual studio) VB has a lot that are pre-defined, but there are only a handful for C#. Do you have any really useful ones for C#? Anyone want to post a good custom one you created yourself? Anyone?... Bueller? ...