473,405 Members | 2,210 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

WriteXml/ReadXml on DataSet and version problems

I am using WriteXML/ReadXml pair to save DataSet for later use. DataSet
is built by reading textfiles and storing their data to different
DataTables. Each file contains several complex values, that are
represented using a DataValue object. DataValue is an abstract class,
that has subclasses that implement the value (for example; ValBlkValue
represents a vector of floating values).

Class DataValue implements IXmlSerializable interface and each subclass
implements WriteXml and ReadXml methods that write or read the value to
the XML file.

This works fine, but XML file contains strong name of the class; for
example:

....
<value msdata:InstanceType="Dmt.GUI.DmtDatasetImport+ValB lkValue,
vmtedit-dmt, Version=1.1.3033.18571, Culture=neutral,
PublicKeyToken=18990d3c7fd98be6"
xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<ValBlkValue datakind="valblkKind" count="9776" len="9">
<vbv>545.8157959</vbv>
<vbv>6.93030977</vbv>
<vbv>44.65736008</vbv>
<vbv>-12.41137695</vbv>
<vbv>-8.45540428</vbv>
<vbv>5.44249964</vbv>
<vbv>-7.45017338</vbv>
<vbv>0</vbv>
<vbv>0</vbv>
</ValBlkValue>
</value>

When I compile new version of the program, ReadXml (actually
ReadXmlSchema, since I tried to put the schema to a separate file) crashes:

ERROR 1 Dmt.GUI.DmtDatasetImport - error reading file: Could not load
file or assembly 'vmtedit-dmt, Version=1.1.3033.18571, Culture=neutral,
PublicKeyToken=18990d3c7fd98be6' or one of its dependencies. The located
assembly's manifest definition does not match the assembly reference.
(Exception from HRESULT: 0x80131040)

So, how can I make either the XmlSerializer not to put the full
classname, or make it ignore small differences in versions?

--
Arto Viitanen
Tampere, Finland
Jun 27 '08 #1
0 1152

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: DraguVaso | last post by:
Hi, I should use XML to synchronize the data from different (VB.NET) applications, and I was just wondering which Overloads of these functions ( ReadXmlSchema, ReadXml and WriteXml) goes the...
2
by: Andreas Palm | last post by:
I have a dataset that has DBNull in certain columns, now when I write out this one to XML, I only get the columns as elements that do have data in it. However I do need also the empty colums as...
0
by: John George | last post by:
I am writing the file correctly and it gives me the right xml file When I read it back, I am missing one element in the last row, it sets it to the initial value before I saved the origional file?...
0
by: hazz | last post by:
I want to load Service.exe.config into a DataGrid, change the timer interval value from 10000 to 555555, then update the original exe.config. The code below shows the code at step 1 and 2 before...
3
by: tasiekk | last post by:
I have typized DataSet. I can add to this dataset whatever i want but some specific date isnt writed to xml file after i make WriteXml. When i add row in code (not by hand in datagridview) it wont...
0
by: Bmack500 | last post by:
Hello all. I'm reading the data from an XML file similiar to below, using the code below. When the file is edited in the datagridview and then re-written, it doesn't write the xml file as it was...
12
by: Rainer Queck | last post by:
Hi NG, I have no idea why, but since a while a dataset refuses to write to a specific xml file. I get the error message "Der Zugriff auf den Pfad...
2
by: Tony Johansson | last post by:
Hello! Assume the following : 1. I create a DataSet with some DataRelation. 2. I then use WriteXml to write the DataSet to an Xml document using DataRelation.Nested = True 3.I then read the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.