Getting Intellisense for Silverlight in VS 2008

Silverlight

I've had a number of people ask me about intellisense with Silverlight 1.0 on VS 2008.  The trick is to *not* use the WPF Editor (the one that won't show Silverlight WPF anyway).  To make it work:

  • Right click the XAML file in the solution and pick "Open With...". 
  • Pick "XML Editor"
  • Click "Set as Default" if you want it to always open XAML files in the XML Editor...

Voila...

Comments:

Gravatar

Interesting. I sometimes get intellisense in the silverlight xaml, but it is not reliable (usually closing the file and reopening will fix it). I don't recall changing the default xaml editor, but maybe I did at some point.

Gravatar

It's a good hack. Problem is - it's a hack.
What if developers need both WPF XAML support in the XAML designer and XML Silverlight support in VS2008?
I don't like hacks just for that reason - Just working doesn't cut it.

It's a nice idea for a VS2008 addin - a "third option" (between XAML or XML editor) that will choose between those editors based on the type of project the XAML file is in or it's contents.

Gravatar

I expect that Silverlight 1.0 will be supported in VS 2008 but this hack is to allow it until the RTM is available. The third option I think is handled by the editor (where you can have a split view or either of the views (XAML or the designer) maximized). If they simply supported Silverlight in Cider (the editor) then we'd be all set.

Gravatar

I did what you mentioned. And also I put the silverlight.xsd into the /xml/schemas/ dir. But I still did not see any intellisense in a xaml file. Any idea what went wrong?

Gravatar

I am seeing the intellisense problem in VS 2008 too. I'll blog when I hear fo a solution.


 



 
Save Cancel