.NET Blog

Free. Cross-platform. Open source. A developer platform for building all your apps.

Creating a Custom Scaffolder for Visual Studio

With the release of Visual Studio 2013 last October, we introduced the concept of Scaffolding to Web Application projects.  Scaffolding is the framework on which code generation for MVC and WebAPI is built.  For more information on Scaffolding or the MVC Scaffolders check the following blog post: http://www.asp.net/visual-studio/...

How to compress CSS/JavaScript before publish/package

Today I saw a post on stackoverflow.com asking Using Microsoft AJAX Minifier with Visual Studio 2010 1-click publish. This is a response to that question. The Web Publishing Pipeline is pretty extensive so it is easy for us to hook in to it in order to perform operation such as these. One of those extension points, as we’ve blogged about...

XDT (web.config) Transforms in non-web projects

One of the really cool features that we shipped for Visual Studio 2010 was web.config (XDT) transformations. Because the transformations are so simple and straightforward one of the first questions that someone asks after using it is “how can I use this in my other projects?” Unfortunately this feature is only built into the Web ...

ASP.NET Web Application: Publish/Package Tokenizing Parameters

  Today I just saw a question posted on stackoverflow.com asking Why are some Web.config transforms tokenised into SetParameters.xml and others are not? Let me give some background on this topic for those who are not aware of what the question is. With Visual Studio 2010 when you package your application using the Build Deployment Package...

The Aspnet Compiler Build Task in Visual Studio 2010 ASP.Net MVC 2 Projects

If you crack open the project file in an ASP.Net MVC 2 application (in notepad or unload your project and then click “Edit *.proj”), you will notice an interesting line. <MvcBuildViews>false</MvcBuildViews> This is an option to enable a post build task that will run the Asp_net compiler. This command will compile your ...

Web Deployment: Excluding Files and Folders via the Web Application’s Project File

Web Deployment (see this posting for an overview) offers a set of pre-determined options to allow users to include the most common sets of files for deployment.  These options are as follows and can be found under the “Items to deploy” section on the Package / Publish Web property page.   Only files needed to run this ...

Issue with dependent assemblies when rebuilding a WAP and the Workarounds

In Visual Studio 2010, the dependent assembly of a custom control assembly will be deleted from the project’s Bin folder on project clean or rebuild if the project does not contain a reference to that dependent assembly. The result will be a WAP that successfully builds but fails at runtime. When adding a control from such a custom control...

Workaround: Missing Declarations for Controls in Designer File

We have seen some customers report the issue that certain controls are not getting generated correctly in the designer file in Visual Studio 2010 RC for the ASP.Net Web Application Projects. We are currently working on a fix for this issue for the final RTM release. Workaround: You can work-around this issue by declaring the missing controls ...

Web Deployment: Web.Config Transformation

We have earlier discussed about Web Deployment and Web Packaging quite a bit, today I wanted to dive into web.config transformation. If you would like to check out the other topics please read through the earlier blog posts below: Usually web applications go through a chain of server deployments before being finally being ...

Feedback usabilla icon