Use VolatileAssembly directive without installing the T4 Toolbox - t4

I'd like to use VolatileAssembly from the T4 Toolbox but do not want to require all developers to install the T4 Toolbox.
Is it possible include the DLL with with project in source control and reference it by path?

In Visual Studio 2010 you are able to do:
<## assembly name="$(ProjectDir)\external\SomeAssembly.dll"#>
Which I believe is what you are asking for.
EDIT: I understand VolatileAssembly is used to reference assemblies without locking them. This is one of the fixes for VS2010 SP1 so if your devs run VS2010 SP1 you shouldn't need VolatileAssembly anymore.

Related

How to use newest MSVC compiler (2017) in old Visual Studio (2010)?

I have a weak computer and the interface of modern Visual Studios (2015/2017) works extremely slowly on it. I'm satisfied with the speed and functionality of the interface of Visual Studio 2010, but I want to use the latest features of C++.
How can I connect the compiler and debugger of VS2017 toolset to the VS2010 IDE?
I'm not sure you can do that. You can try changing the toolset directories. But I highly doubt that will work.
But I can suggest other approaches:
- switch off intellisence and other features of VS
- uninstall VS packages you do not need
- Try Visual Studio Code instead. If you are not tied to Windows, get a Linux OS and use it with Visual Studio Code.
- Otherwise use another editor to code in (like notepad++) and use only the command line to build projects (you cant use the debugger in that case)

Using Roslyn compiler with Visual Studio 2013

Is there a way to use the Roslyn compiler with Visual Studio 2013 so that I can take advantage of the new C# 6 features ?
Note: Using VS 2015 is not an option.
Yes, you can compile C# 6 code with Visual Studio 2013. You just have to install the Microsoft.Net.Compilers NuGet package and your code will build just fine (however, note that you need to target .NET 4.5+).
But, the IDE won't understand it. You'll get squiggles everywhere you try to use a C# 6 feature, because VS2013's internal "live" compiler is not the same. Working in such an environment on a daily basis will drive you insane in less than two weeks.
That said, if all you need is compiling C# 6 code, installing the NuGet package on VS2013 is a potential solution.

DebuggingVisualizer targeting multiple versions of Visual Studio

Is it possible to build a Debugging Visualizer that can be used in multiple versions of Visual Studio?
A Debugging Visualizer has to reference Microsoft.VisualStudio.DebuggerVisualizers.dll and there is a separate version of the assembly for every version of Visual Studio. It seems that these versions are not compatible. For example, if I built a visualizer that references Microsoft.VisualStudio.DebuggerVisualizers v9.0, it can be used in Visual Studio 2008, but not in Visual Studio 2010.
I am looking for a way to target at least Visual studio 2008 and Visual Studio 2010 while maintaining only one project for the visualizer. Duplicating the project and changing only references to Microsoft.VisualStudio.DebuggerVisualizers will work, but it creates a maintenance horror.
If your code base is exactly the same for both referenced assemblies then I would suggest the same approach as I've suggested in this question: Visual Studio Installer -- Change application resource
The idea is to have 1 project where you will have a MSBuild property which VS to target and depending on this property you may reference either VS 2008 or VS 2010 DebuggerVisualizers assembly.
The only other solution I see is the one you've mentioned - having 2 separate project files to target different VS version. I do not think it will be that difficult to maintain two versions if you will not duplicate code. And you can avoid duplicating code by including code files as links into your projects.

Using DLL's in Visual Studio 2010 C++ project

I am trying to use a DLL in a Visual Studio 2010 C++ project . I followed the directions here but http://msdn.microsoft.com/en-us/library/ms235636(v=vs.80).aspx I cannot seem to add references to my project.
When I open add reference there is no way for me to add any references, as shown below.
What am I doing wrong here?
You are using the wrong version of the tutorial. It is created for Visual Studio 2005 and you are using Visual Studio 2010. This is the correct version.
The problem here (I think) is that you didn't "add to solution" when creating the project that will utilize the dll file.
edit: or you might have forgotten to compile your dll

Are there any websites dedicated to the distribution of Visual Studio Macros?

Preferably a site that has macros searchable by Visual Studio version.
Well, the web's top Visual Studio project site is http://www.codeproject.com. You'll find lots of macros there.
Specifically, check http://www.codeproject.com/KB/macros/
I think there is no specific search for Studio versions, but each macro in there carry its own compatibility specification.

Resources