I am working on CI for my team,  new projects are using .net framework 4.5, our server 2008 also has framework4.5 installed, but My TFS2012 still got Error like this:
The application pool that you are trying to use has the 'managedRuntimeVersion' property set to 'v4.0'. This application requires 'v4.5'

There are two solutions I tried can fix this issue.
both need use a textpad edit the project file:
Add one of below before <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>:

<IgnoreDeployManagedRuntimeVersion>True</IgnoreDeployManagedRuntimeVersion>
or
<DeployManagedRuntimeVersion>v4.0</DeployManagedRuntimeVersion>

ref
http://stackoverflow.com/questions/19834307/msdeploy-cannot-deploy-net-v4-5-package-to-v4-0-application-pool


 
Categories: Agile | Asp.net | Visual studio 10/up

There is full lists :link

First we take look the Tools related with Visual Studio:

MSTest, the unit test framework in Visual Studio

Coded UI Test

Microsoft Fakes,

Microfoft Test Manager

Visual Studio Memory Profiler

Visual Studio Performance profiler

Visual Studio Load Test, part of VS Ultimate(Testing Performance and Stress Using Visual Studio Web Performance and Load Tests)

TestDriven.Net, unit test running for Visual Studio


Other Test tools I have used:

nUnit,

JetBrains ReSharper UnitTest , 

moq,

SpecFlow




 
Categories: Agile | UnitTest | Visual studio 10/up

http://referencesource.microsoft.com/netframework.aspx

the download page only work under IE ;)

Available Source Code Components

 

Product NameVersionViewDownload
.NET8.0View EULADownload
dotnetfx1434_VistaWin2k8sp150727.1434View EULADownload
FXUpdate307450727.3074View EULADownload
ASP.NET_MVC1.0View EULADownload
WCF3.5SP1View EULADownload
WF3.5SP1View EULADownload
Dotnetfx_Vista_SP250727.4016View EULADownload
Dotnetfx_Win7_3.5.13.5.1View EULADownload
ASP.NET_MVC2.0View EULADownload
.Net4View EULADownload
.NET_3.5_sp1_redist50727.3053View EULADownload
ASP.NET_MVC3View EULADownload
Netfx_3.5.1_Win7SP13.5.1View EULADownload
NET4.5View EULADownload
Net4.5Update1View EULADownload


 
Categories: Asp.net | C# | MVC | Visual studio 10/up | WCF

I am working on the SAML authentication for our Mobile app,
get some resource to build my test SAML Identity Service Party

http://www.componentpro.com/download/?name=UltimateSaml
http://www.componentpro.com/doc/saml/Introduction_to_Single_Sign-On_Applications.html

http://www.componentspace.com/Downloads.aspx

to create private key and public key,
we can use Visualstudio command line makecert.exe, but easiest way is using the gui tool from:
http://blog.pluralsight.com/selfcert-create-a-self-signed-certificate-interactively-gui-or-programmatically-in-net

first save the rsa key to pfx file by use selfcert tool.

then you can import it and export to to cer file.
you need use "mmc" command and add certificate snap to view the certificates.

or you can use openssl (need install it first),

C:\Users\wsun>openssl pkcs12 -nokeys -clcerts -in ix.pfx -out ix.cer
Enter Import Password:
MAC verified OK


 
Categories: C# | Security | Visual studio 10/up

Tools-> Library Package Manager -> Package Manager Console

PM> Install-Package jQuery-vsdoc -Version 1.10.2
PM> Install-Package jquery.mobile
PM>
Install-Package Microsoft.AspNet.SignalR -Version 1.1.3
PM> Install-Package knockoutjs
PM> Install-Package Modernizr
PM> Install-Package jQuery.UI.Combined


 
Categories: JQuery | Visual studio 10/up

If the symbol is defined, the call is included; otherwise, the call is omitted. Conditional methods provide a cleaner, more elegant alternative to enclosing the method call in #if conditionalSymbol...#endif preprocessor directives.(http://msdn.microsoft.com/en-us/library/4xssyw96%28v=vs.71%29.aspx)
Using the Conditional attribute, you can isolate functions that should be part of your classes only when a particular environment variable is defined or set to a certain value.
The Conditional attribute generates more efficient IL than #if /#endif  does. It also has the advantage of being applicable only at the function level, which forces you to better structure your conditional code. (Effective C#:50 Specific Ways to Improve Your C# by Bill Wagner (Mar 15, 2010))


 
Categories: C# | IoC | MVC | Visual studio 10/up

Create a no Form Wizard for children template, use static properties to take value from Main Wizard.
using System;
using System.Collections.Generic;
using Microsoft.VisualStudio.TemplateWizard;
using System.Windows.Forms;
using EnvDTE;

namespace CustomWizard
{
    public class NewWidgetTemplateWizard : IWizard
    {
        private UserInputForm _inputForm;
        private string _projectName;
        private int _portNumber;
        private string _releaseSchema;
        private Guid _projectGuid;
     
        #region Implementation of IWizard

        public void RunStarted(object automationObject, Dictionary<string, string> replacementsDictionary, WizardRunKind runKind, object[] customParams)
        {

            try
            {
               
                    _inputForm = new UserInputForm();
                    _inputForm.ShowDialog();
                    _projectName = _inputForm.ProjectName;
                    _portNumber = _inputForm.PortNumber;
                    _releaseSchema = _inputForm.ReleaseSchema;
                    _projectGuid = Guid.NewGuid();

                replacementsDictionary.Add("$ProjectName$",
                        _projectName );
               
                SetUpChild();

            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }

        private void SetUpChild()
        {
            NewWidgetTemplateWizardChild.PortNumber = this._portNumber;
            NewWidgetTemplateWizardChild.ProjectName = this._projectName;
            NewWidgetTemplateWizardChild.ReleaseSchema = this._releaseSchema;
            NewWidgetTemplateWizardChild.ProjectGuid = this._projectGuid;
        }
Supper simple solution..


 
Categories: Visual studio 10/up | VS 2005 | VS 2008

root2.template
<VSTemplate Version="2.0.0" Type="ProjectGroup"
    xmlns="http://schemas.microsoft.com/developer/vstemplate/2005">
    <TemplateData>
        <Name>New Widget Templates</Name>
        <Description> inlucde new widget template and widgetTests template</Description>
        <Icon>Icon.ico</Icon>
        <ProjectType>CSharp</ProjectType>
    </TemplateData>
    <TemplateContent>
        <ProjectCollection>
            <ProjectTemplateLink ProjectName="Widgets.$safeprojectname$">
                NewWidgetTemplate2\NewWidget.vstemplate
            </ProjectTemplateLink>
            <ProjectTemplateLink ProjectName="Widgets.$safeprojectname$.Tests">
                NewWidgetTestsTemplate2\NewWidgetTests.vstemplate
            </ProjectTemplateLink>
        </ProjectCollection>
    </TemplateContent>
    <WizardExtension>
    <Assembly>CustomWizard, Version=1.0.0.0, Culture=Neutral, PublicKeyToken=fbf8d46e0d2fda8f</Assembly>
    <FullClassName>CustomWizard.NewWidgetTemplateWizard</FullClassName>
</WizardExtension>

</VSTemplate>


 
Categories: Visual studio 10/up | VS 2005

Custom Project Template with Wizard, create the new class with the name of custom value.
 
Categories: Asp.net | C# | Visual studio 10/up | VS 2008