HighTechTalks DotNet Forums  

XML Attribute

Dotnet XML microsoft.public.dotnet.xml


Discuss XML Attribute in the Dotnet XML forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Vi
 
Posts: n/a

Default XML Attribute - 06-27-2006 , 11:56 AM






I have to serialize a class to an XML file. The root element needs to have
the following attribute: xsi:noNamespaceSchemaLocation="..\Order.xsd"

Here's the property definition:
[XmlAttribute("xsi:noNamespaceSchemaLocation")]
public string noNamespaceSchemaLocation;

But this gives me the runtime error: {"There was an error reflecting field
'noNamespaceSchemaLocation'."} with the InnerException {"Invalid name
character in 'xsi:noNamespaceSchemaLocation'."}

Thanks.

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.