TFS: different .NET framework projects in the same solution? - visual-studio

I have a TFS project that has multiple .NET 3.5 projects.
I want to create a windows phone 8 project in the same solution cause it will reference a a .NET 3.5 library project and a WCF project.
when my colleagues get the latest version from the TFS, they can't load the solution cause they don't have Visual Studio 2012 (which is used for the windows phone project).
is there a way to add my windows phone project to the TFS solution without affecting the other older framework projects ?

I suggest you to add your project normally (Add Existing project to source control), but when you chenck in, you don't check in your solution file. with this solution you save your code in repository without affecting basic behavior

Related

Visual Studio 2019 is not working correctly for Windows Forms Projects

We are worming on Windows forms project which uses CAB Architecture and Infragistics Ultra Win Controls .
We have a common project which is being used in almost every project and have custom controls (Wrapper over infragistics controls).
Till .Net framework 4.7 and Visual Studio 2017 everything was working fine but when we have upgraded our solution to .net framework 4.8 and visual studio to 2019 (16.6.4 current version) along with infragistics control latest version, it starts creating issues for us. Below things stopped working at all.
Edit & Continue (Tried all possible combinations from stackoverflow and google responses)
IntelliSense (works on few projects)
References Navigation (works in few files)
After upgrade, we have removed all obj and bin folders, deleted .vs folder and rebuild solution. Also refreshed each project one by one.
I can rebuild, run and debug the application but can not edit code during debugging.
If anyone have any solution, then it will be a great help. We are feeling like coding in NotePad due to above issues.
Here is my Visual Studio Configuration
Issue was with the Windows Form project which uses CAB architecture and custom controls.
After reporting it to microsoft they have pushed some updated in the newest version and now everything is working fine.

ASP.NET Core precompiled views on publish

I've previously created an ASP.NET Core project with .NET Core 2.0 preview 1 and Visual Studio 2017 15.3 preview. Just the default stuff from the project template, no custom code yet. Then I used the Publish command and have everything copied to the directory bin\Release\PublishOutput. All nice and good. 5 MB, can be deployed to the production web server and it works.
Now I've tried the same thing with VS Code and just won't get anywhere. I created the project with dotnet new mvc and opened it in VS Code with code .. After closing and opening it a few times and editing .cs files, I think I've now jumped over all the hurdles that VS Code comes with. I can run the application locally.
But the publishing doesn't quite produce the desired result. I run dotnet publish -c Release manually because VS Code doesn't seem to offer anything here. I get tons of files in bin\Release\netcoreapp2.0, along with a subdirectory called publish. Both have a copy of MySite.dll and MySite.pdb, but no precompiled views DLL. Also, the publish directory has 54 MB of runtime DLLs that weren't required for what Visual Studio gave me.
What is the intended method to publish an ASP.NET Core MVC application with VS Code? Everything is the latest version, downloaded and installed today.
Do I need components from the full Visual Studio to get the complete publishing experience, with all the advertised features?
For the record, I have recently discovered in ASP.NET Core 2.0 preview 2 that this has been resolved. A project created with dotnet new mvc has the MvcRazorCompileOnPublish property set in the csproj file, and dotnet publish does the same as publishing through Visual Studio 2017 (15.3) now.

Share files between projects in visual studio 2013?

I have a F# project which is compiled for .Net 4.5. However, I need it to be compiled .Net 4.0 too. I created another project target .Net 4.0 and I can copy all the same files from the .Net 4.5 project to the newly created project.
The project referred some NuGet libraries which have different packages for .Net 4.5 and 4.0 so I cannot simply change the project's .Net version and recompile. How to avoid maintain two copies of the same files? I know VS 2015 has shared files function.
try "Add As Link".
Project menu > Add Existing Item... and in the Add drop-down list, click Add As Link.
I think you would be better off using source control to share files.
The source control has one copy.
Having a multiple copies on your hard drive is actually a good thing. One project can use a stable version while another project updates and tests a new version.
The only disadvantage is if one project checks in changes, you must remember to do a 'get' for the other projects.

Shared Project with RC update 2 for Visual Studio 2013

I recently installed the RC update 2 for Visual Studio 2013. When going through the template for a universal app I found a project *******.Shared which had an extension .shproj.
When going through some material online what I found was it is - a project template to share code and files, which I thought is so cool. But as I started working on it, I hit a roadblock. How do I add references to this project? Has anyone worked this out?
There is no need to add references for the shared code. Just add necessary reference to your Windows Store or Windows Phone project. It works fine for both (shared and specific projects).
For Visual Studio 2013 Updates 2 & 3 (and probably 4), install and use the Shared Project Reference Manager Visual Studio extension to allow shared code projects to be referenced from other projects in a solution.
It does have an odd dependency on having a Windows Phone developer licence, even if you do not have a Windows Phone project in your solution, but I assume that dependency will be dropped at some point.

Cannot convert existing ASP.NET MVC 2 solution to Azure Web Role in Visual Studio 2010

I've been working on an ASP.NET MVC 2 (.NET 4.0, Visual Studio 2010) application for a while and have decided that I would like to deploy it as an Azure application.
After installing the latest (June 2010) Azure tools (through Visual Studio itself) I've added a blank CloudService to my solution. Whenever I try to add a "Web Role Project in Solution", however, I get the following error:
An error occurred trying to load the project properties window.
Close the window and try again.
Cannot evaluate the item metadata "%(FullPath)".
The item metadata "%(FullPath)" cannot be applied to the path
"obj\Debug|Any CPU\Cloud.dll". Illegal characters in path.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets
I get this same error whenever I try to Save All or view the properties page for the CloudService project.
I imagine it's having trouble with the Debug|Any CPU part of the path, but can I remove it or word around it?
Thanks in advance
Well, what do you know. When had already sort of given up on this, seeing as how I could run en deploy the application anyway I decided to try one last time and ended up finding the solution on this article:
http://tomkrueger.wordpress.com/2010/07/27/azure-deployment-issue-after-upgrading-to-visual-studio-2010-and-net-4-0/
The problem started because I actually added an Azure project to an existing ASP.NET MVC solution there were some unnecessary settings left over in the web.csproj file.
All I had to do was open web.csproj in notepad and remove all occurrences of the <PlatformTarget> element.
My MVC prjoject was x86 and of course Azure works on x64 only. Even though I had the platform target set up as AnyCPU somehow Azure couldn't quite get along with it.
Have you downloaded the latest Azure SDK? .NET 4 was not supported before the June 2010 version of the SDK.
Windows Azure Software Development Kit (June 2010)
Windows Azure Tools for Microsoft Visual Studio 1.2 (June 2010)

Resources