BUG: Compiler Error When You Use XmlAttribute (326706)
The information in this article applies to:
- Microsoft Visual J# .NET (2002)
This article was previously published under Q326706 SYMPTOMS When you compile a Visual J# .NET application that imports
from both System.Xml and System.Xml.Serialization and that uses the attribute XmlAttribute, you receive the following compiler error message:
error VJS1397: Attribute 'System.Xml.XmlAttribute'
doesn't inherit from 'System.Attribute' CAUSE The compiler confuses the class System.Xml.XmlAttribute with the attribute class System.Xml.Serialization.XmlAttributeAttribute. This occurs because both System.Xml and System.Xml.Serialization packages are imported and the short form for XmlAttributeAttribute is XmlAttribute. RESOLUTION To work around this problem, fully qualify the attribute
class name ( XmlAttributeAttribute):
/**@attribute XmlAttributeAttribute("test")*/
public String helpstring;
STATUSMicrosoft has confirmed that this is a bug in the Microsoft
products that are listed at the beginning of this article.
Modification Type: | Major | Last Reviewed: | 1/27/2004 |
---|
Keywords: | kbbug kbpending KB326706 |
---|
|