Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I have an XML file that is related to an XML Schema. Then I open the file in
Excel, edit some data, and save the file as XML Data. Problem: The resulting XML file is no longer related to the XML Schema. If I do the same in Word (Office Professional 2003), the schemaLocation attribute is kept. How can I make sure this happens in Excel (Office Professional 2003) as well? Alternative angle: I don't want to lose the empty elements when saving to an XML file from Excel. As long as the XML file is related to the schema, these elements are kept. But if one edits the file a second time, since it is no longer related to the schema, the empty elements will be lost. Is it perhaps possible to solve it some other way than through keeping the schema relation? Simple example of the xml file: <?xml version="1.0" encoding="ISO-8859-1"? <EquInfo xmlns="http://www.yyy.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.yyy.com exampleSchema.xsd" <Row rowId="1" <EquipmentEquNewType</Equipment <Manufacturer</Manufacturer <Model</Model </Row </EquInfo The XML Schema: <?xml version="1.0"? <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.yyy.com" xmlns="http://www.yyy.com" elementFormDefault="qualified" <xs:element name="EquInfo" <xs:complexType <xs:sequence <xs:element name="Row" maxOccurs="unbounded" <xs:complexType <xs:sequence <xs:element name="Equipment" type="xs:string"/ <xs:element name="Manufacturer" type="xs:string"/ <xs:element name="Model" type="xs:string"/ </xs:sequence <xs:attribute name="rowId" type="xs:positiveInteger" use="required"/ </xs:complexType </xs:element </xs:sequence </xs:complexType </xs:element </xs:schema Thank you in advance! best regards, Erik Braten |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Caption attribute at Cell in Excel XML | Excel Discussion (Misc queries) | |||
Saving data in Excel | Excel Discussion (Misc queries) | |||
sorting data by a certain attribute | Excel Worksheet Functions | |||
How do I change the default attribute in excel? | Excel Discussion (Misc queries) | |||
the attribute "nullable" is not supported in convert excel to xml | Excel Discussion (Misc queries) |