473,386 Members | 1,621 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,386 software developers and data experts.

Problem with XMLSerializer

Hello all.

The following code...

Dim objXMLSerializer As XmlSerializer

objXMLSerializer = New XmlSerializer(GetType(Settings))

....generates the following exception in my application...

An unhandled exception of type 'System.IO.FileNotFoundException'
occurred in mscorlib.dll
Additional information: File or assembly name twcpkrac.dll, or one of
its dependencies, was not found.

The DLL name is always a 'random' string of characters.

Any ideas why?

--
ROT13 my email address to reply directly: qn*****@gpd.arg

Nov 20 '05 #1
3 1563
I always use something similar to this when creating a serializer...

objXMLSerializer = New XmlSerializer(Settings.GetType())

I don't know if that would make a difference, but it is worth a shot.

HTH,

Doug Perkes

"David Pendleton" <qn*****@gpd.arg> wrote in message
news:uO*************@TK2MSFTNGP09.phx.gbl...
Hello all.

The following code...

Dim objXMLSerializer As XmlSerializer

objXMLSerializer = New XmlSerializer(GetType(Settings))

...generates the following exception in my application...

An unhandled exception of type 'System.IO.FileNotFoundException'
occurred in mscorlib.dll
Additional information: File or assembly name twcpkrac.dll, or one of
its dependencies, was not found.

The DLL name is always a 'random' string of characters.

Any ideas why?

--
ROT13 my email address to reply directly: qn*****@gpd.arg

Nov 20 '05 #2
Thanks, but that didn't work either.

--
ROT13 my email address to reply: qn*****@gpd.arg

"Doug Perkes" <do********@msn.com> wrote in message
news:Oz**************@TK2MSFTNGP10.phx.gbl...
I always use something similar to this when creating a serializer...

objXMLSerializer = New XmlSerializer(Settings.GetType())

I don't know if that would make a difference, but it is worth a shot.

HTH,

Doug Perkes

"David Pendleton" <qn*****@gpd.arg> wrote in message
news:uO*************@TK2MSFTNGP09.phx.gbl...
Hello all.

The following code...

Dim objXMLSerializer As XmlSerializer

objXMLSerializer = New XmlSerializer(GetType(Settings))

...generates the following exception in my application...

An unhandled exception of type 'System.IO.FileNotFoundException'
occurred in mscorlib.dll
Additional information: File or assembly name twcpkrac.dll, or one of its dependencies, was not found.

The DLL name is always a 'random' string of characters.

Any ideas why?

--
ROT13 my email address to reply directly: qn*****@gpd.arg


Nov 20 '05 #3
I found the problem, but am unsure about the details behind it.

My class, 'Settings' was declared within my Form class. Apparently, this is
a no-no as far as serialization is concerned; it worked fine once I moved it
to it's own class module.

--
ROT13 my email address to reply: qn*****@gpd.arg

"Doug Perkes" <do********@msn.com> wrote in message
news:Oz**************@TK2MSFTNGP10.phx.gbl...
I always use something similar to this when creating a serializer...

objXMLSerializer = New XmlSerializer(Settings.GetType())

I don't know if that would make a difference, but it is worth a shot.

HTH,

Doug Perkes

"David Pendleton" <qn*****@gpd.arg> wrote in message
news:uO*************@TK2MSFTNGP09.phx.gbl...
Hello all.

The following code...

Dim objXMLSerializer As XmlSerializer

objXMLSerializer = New XmlSerializer(GetType(Settings))

...generates the following exception in my application...

An unhandled exception of type 'System.IO.FileNotFoundException'
occurred in mscorlib.dll
Additional information: File or assembly name twcpkrac.dll, or one of its dependencies, was not found.

The DLL name is always a 'random' string of characters.

Any ideas why?

--
ROT13 my email address to reply directly: qn*****@gpd.arg


Nov 20 '05 #4

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

Similar topics

1
by: Thomas | last post by:
Hi, I implemented a composite pattern which should be serializable to xml. After spending some time in the newsgroups, i finally managed serializing, even with utf-8 instead of utf-16, which...
11
by: Nick Flandry | last post by:
Hi all, When I run this code: XmlSerializer theXS; try { theXS = new XmlSerializer(typeof(TableInfo)); } catch( System.Exception eAll )
3
by: Mark | last post by:
Hi all, i'm trying to serialize a class. Using the constructor of XmlSerializer i get these (odd?) errors: "File or assembly name goseij9w.dll, or one of its dependencies, was not found"....
12
by: SJD | last post by:
I've just read Christoph Schittko's article on XmlSerializer: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnxmlnet/html/trblshtxsd.asp . . . and very informative it is too....
1
by: Sacha | last post by:
I'm having trouble serializing some of my classes when using late binding. When I don't use late binding, it works fine. MyClass inherit from an abstract class called AbsMyClass. If I do the...
0
by: David Preuss | last post by:
Hi all, i have a problem with a class which has several subclasses embedded when trying to deserialize it. Serializing works just fine. The xml is as follows: <?xml version="1.0"...
4
by: pei_world | last post by:
I have followed a example from a book exactly, but it seems not working at all. can anyone tell me what is going on? ========= Global.asax.cs ============ public static Entry...
1
by: Curious | last post by:
Hi, I am trying to use the following code to make xml serialization to a file. The following error is being given: "An unhandled exception of type 'System.InvalidOperationException' occurred...
0
by: Kapil Joshi | last post by:
Hi, This issue is related to System.Xml.Serialization.XmlElementArrayAttribute class. We are using VS.NET 2005 (RTM) Professional Edition version 8.0.50727.42 (RTM.050727-4200)....
2
by: OllieHag | last post by:
Hi, can anyone help me out with this problem? In the code posted below, why does my count of Data objects only return 1, not 3. If I comment out the IXmlSerializable inheritance in the Data class,...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.