CS0103: The name ‘InitializeComponent’ does not exist in the current context

|  Posted: February 8, 2011  |  Categories: General Technical
Tags:

When you are trying to build a solution that contains Silverlight or WPF projects using MsBuild you may encounter the error “CS0103: The name ‘InitializeComponent’ does not exist in the current context”. While searching I have found various tactics that involves editing the project files, including namespaces etc.

 

But the real reason is you are using the wrong version of Msbuild. Multiple versions of Msbuild gets installs in your machine, through various versions of .NET framework, Visual Studio etc. So, check the path variables and make sure you are using the correct version. If you are using Silverlight 4, you need to use MsBuild.

Nandri!

Saravana

Author: Saravana Kumar

Saravana Kumar is the Founder and CTO of BizTalk360, an enterprise software that acts as an all-in-one solution for better administration, operation, support and monitoring of Microsoft BizTalk Server environments.

  • Gaurav

    how can i check MSBuild version

One Platform Operations, Monitoring and Analytics Software
BizTalk360

microsoft biztalk

Learn more

Over 500 customers across 30+ countries depend on BizTalk360

ServiceBus360

Azure service bus

Learn more

Start managing your Azure Service Bus namespaces in minutes

One Platform - Operations, Monitoring and Analytics Software
BizTalk360

microsoft biztalk

Learn more

Over 500 customers across 30+ countries depend on BizTalk360

One Platform - Operations, Monitoring and Analytics Software
ServiceBus360

Azure service bus

Learn more

Start managing your Azure Service Bus namespaces in minutes

Back to Top