- September 24, 2006
- 70
- 25
- 44
- Home Country
- Netherlands
Hi people,
I'm working on an improvement of the Global Search plug-in, but I got stuck on the serialization part of the configuration. I'm trying to read and write it to a file on disk, but it doesn't work. Searching this forum, I found the following thread which describes the *precise* problem I have. The last message in the thread states that the original poster should cross-check it with another post, but when I click that, I come to a page in German that has nothing to do with serialization (I think).
Here's the original thread: https://forum.team-mediaportal.com/plugins-47/error-failed-locate-assembly-560/.
Here's the code I try to execute which fails:
Here's the error message I get when this is executed (the bold line triggers the error):
My questions:
1. Can someone help me getting this to work?
2. If not, can someone check if the 'cross-check' link is correct and if so, what it means?
3. Why the heck DOES this work when I run it in a normal Windows Application (!!!!) ?
grtz,
d-fader
Hmm, I built GlobalSearch with the SVN tag for version 1.0 RC2 and now it seems to work. I used to build with some trunk version of 0.2.3, can anyone tell me what was wrong with that version? thnx.
I'm working on an improvement of the Global Search plug-in, but I got stuck on the serialization part of the configuration. I'm trying to read and write it to a file on disk, but it doesn't work. Searching this forum, I found the following thread which describes the *precise* problem I have. The last message in the thread states that the original poster should cross-check it with another post, but when I click that, I come to a page in German that has nothing to do with serialization (I think).
Here's the original thread: https://forum.team-mediaportal.com/plugins-47/error-failed-locate-assembly-560/.
Here's the code I try to execute which fails:
Code:
public bool LoadFromFile(string filename)
{
try
{
XmlSerializer serializer = new XmlSerializer(typeof(GlobalSearchSettings));
TextReader reader = new StreamReader(filename);
[b]globalSearchSettings = (GlobalSearchSettings)serializer.Deserialize(reader);[/b]
reader.Close();
return true;
}
catch (Exception e)
{
return false;
}
}
Here's the error message I get when this is executed (the bold line triggers the error):
My questions:
1. Can someone help me getting this to work?
2. If not, can someone check if the 'cross-check' link is correct and if so, what it means?
3. Why the heck DOES this work when I run it in a normal Windows Application (!!!!) ?
grtz,
d-fader
Hmm, I built GlobalSearch with the SVN tag for version 1.0 RC2 and now it seems to work. I used to build with some trunk version of 0.2.3, can anyone tell me what was wrong with that version? thnx.