XML / XSD intellisense not working in Visual Studio 2010

I am working on xml and xsd files in VS 2010, but intellisense is not working. However, Intellisense works for the same files in VS 2008.

When I enter the parameters "<xs:" such as "attribute", "complexType", "simpleType" or "element" are not displayed.

Is there any difference between VS 2008 and VS 2010 that I am missing?

I am adding an xsd file to my solution. All native namespaces are automatically generated as such:

<?xml version="1.0" encoding="utf-8"?> <xs:schema id="XMLSchema2" targetNamespace="http://tempuri.org/XMLSchema2.xsd" elementFormDefault="qualified" xmlns="http://tempuri.org/XMLSchema2.xsd" xmlns:mstns="http://tempuri.org/XMLSchema2.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema"> </xs:schema> 

"xsdschema.xsd" is located in the directory "C: \ Program Files \ Microsoft Visual Studio 10.0 \ xml \ Schemas".

The XML Schema dialog box has a checkmark in the Use column.

+6
xml visual-studio-2010 xsd intellisense
Jun 06 '10 at 23:35
source share
2 answers

I discovered what happened. Visual Studio 2010 imported the schemas from Visual Studio 2008. This triggered duplication warnings, as shown below:

 Warning The global attribute 'http://www.w3.org/XML/1998/namespace:lang' has already been declared. C:\Program Files\Microsoft Visual Studio 10.0\xml\Schemas\xml.xsd 

In the XML Schema dialog box, I deleted old schemas from the cache. You will have to restart Visual Studio.

+10
Jun 07 '10 at 4:11
source share

Validation of intellisense and schema will disappear if warnings are not resolved; for example, the presence of duplicates of complex types in different files that have the same schema namespace.

+2
Jul 21 2018-11-11T00:
source share



All Articles