-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: [Resolved] Exception: What is the meaning of this?
PostPosted: Mon Jun 19, 2006 11:08 pm 
Beginner
Beginner

Joined: Tue May 23, 2006 12:53 am
Posts: 34
Code:
TestCase 'NBulletin.Commands.Test.CommandTest.Test1'
failed: System.TypeInitializationException : The type initializer for "NBulletin.Utilities.ConfigurationSingleton" threw an exception.
  ----> System.Xml.XmlException : This is an unexpected token. The expected token is 'NAME'. Line 3, position 53.
   at NBulletin.Utilities.ConfigurationSingleton.get_Instance()
   D:\ian\projects\csharp\nbulletin\nbulletinData\Commands\Commands.cs(28,0): at NBulletin.Commands.Save.Execute()
   D:\ian\projects\csharp\nbulletin\nbulletinData\Commands\Test\CommandTest.cs(24,0): at NBulletin.Commands.Test.CommandTest.Test1()
   --TypeInitializationException
   at System.Xml.XmlTextReader.ParseElement()
   at System.Xml.XmlTextReader.Read()
   at NHibernate.Cfg.AssemblyHbmOrderer.GetHbmFiles()
   at NHibernate.Cfg.Configuration.AddAssembly(Assembly assembly, Boolean skipOrdering)
   at NHibernate.Cfg.Configuration.AddAssembly(String assemblyName)
   D:\ian\projects\csharp\nbulletin\nbulletinData\Utilities\ConfigurationSingleton.cs(30,0): at NBulletin.Utilities.ConfigurationSingleton..ctor()
   D:\ian\projects\csharp\nbulletin\nbulletinData\Utilities\ConfigurationSingleton.cs(22,0): at NBulletin.Utilities.ConfigurationSingleton..cctor()

TestFixture failed:


0 passed, 1 failed, 0 skipped, took 0.75 seconds.


Last edited by nebulom on Tue Jun 20, 2006 5:37 am, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Exception: What is the meaning of this?
PostPosted: Tue Jun 20, 2006 2:59 am 
Expert
Expert

Joined: Thu Jan 19, 2006 4:29 pm
Posts: 348
nebulom wrote:
Code:
TestCase 'NBulletin.Commands.Test.CommandTest.Test1'
failed: System.TypeInitializationException : The type initializer for "NBulletin.Utilities.ConfigurationSingleton" threw an exception.
  ----> System.Xml.XmlException : This is an unexpected token. The expected token is 'NAME'. Line 3, position 53.
   at NBulletin.Utilities.ConfigurationSingleton.get_Instance()


It might mean that the xml file beeing read (app.config, for example) contains a little bit "invalid" XML for NBulletin.Utilities.ConfigurationSingleton class.

I havn't done much work with .Net configuration, but (in case I remember correctly) if accessed trought typed class, it requires that the attributes are in exacty correct order, no omissions, no additions. It might be possible to tweak them using attributes.

Gert

_________________
If a reply helps You, rate it!


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 20, 2006 4:26 am 
Beginner
Beginner

Joined: Tue May 23, 2006 12:53 am
Posts: 34
Thanks gert, yeah it has something in the App.config

Again, thanks!


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.