Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8567757
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T17:57:15+00:00 2026-06-11T17:57:15+00:00

[CannotLoadObjectTypeException: Cannot resolve type [Jtx.Service.Implement.UserManager,Jtx.Service] for object with name ‘UserManager’ defined in assembly [Jtx.Web,

  • 0
[CannotLoadObjectTypeException: Cannot resolve type [Jtx.Service.Implement.UserManager,Jtx.Service] for object with name 'UserManager' defined in assembly [Jtx.Web, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null], resource [Jtx.Web.Config.Controllers.xml] line 3]
   Spring.Objects.Factory.Support.AbstractObjectFactory.ResolveObjectType(RootObjectDefinition rod, String objectName) in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Objects\Factory\Support\AbstractObjectFactory.cs:1100
   Spring.Objects.Factory.Support.DefaultListableObjectFactory.PreInstantiateSingletons() in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Objects\Factory\Support\DefaultListableObjectFactory.cs:472
   Spring.Context.Support.AbstractApplicationContext.Refresh() in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Context\Support\AbstractApplicationContext.cs:1017
   Spring.Context.Support.WebApplicationContext..ctor(WebApplicationContextArgs args) in c:\_prj\spring-net\trunk\src\Spring\Spring.Web\Context\Support\WebApplicationContext.cs:125
   Spring.Context.Support.WebApplicationContext..ctor(String name, Boolean caseSensitive, String[] configurationLocations) in c:\_prj\spring-net\trunk\src\Spring\Spring.Web\Context\Support\WebApplicationContext.cs:82
   _dynamic_Spring.Context.Support.WebApplicationContext..ctor(Object[] ) in c:\_prj\spring-net\trunk\src\Spring\Spring.Web\Caching\AspNetCache.cs:126
   Spring.Reflection.Dynamic.SafeConstructor.Invoke(Object[] arguments) in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Reflection\Dynamic\DynamicConstructor.cs:116
   Spring.Context.Support.RootContextInstantiator.InvokeContextConstructor(ConstructorInfo ctor) in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Context\Support\ContextHandler.cs:563
   Spring.Context.Support.ContextInstantiator.InstantiateContext() in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Context\Support\ContextHandler.cs:508
   Spring.Context.Support.ContextHandler.InstantiateContext(IApplicationContext parentContext, Object configContext, String contextName, Type contextType, Boolean caseSensitive, String[] resources) in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Context\Support\ContextHandler.cs:351
   Spring.Context.Support.WebContextHandler.InstantiateContext(IApplicationContext parent, Object configContext, String contextName, Type contextType, Boolean caseSensitive, String[] resources) in c:\_prj\spring-net\trunk\src\Spring\Spring.Web\Context\Support\WebContextHandler.cs:127
   Spring.Context.Support.ContextHandler.Create(Object parent, Object configContext, XmlNode section) in c:\_prj\spring-net\trunk\src\Spring\Spring.Core\Context\Support\ContextHandler.cs:289

Service.xml

<?xml version="1.0" encoding="utf-8" ?>
<objects xmlns="http://www.springframework.net">
  <object id="UserManager" type="Jtx.Service.Implement.UserManager,Jtx.Service" parent="BaseTransactionManager">
    <property name="CurrentRepository" ref="UserRepository"/>
  </object>
</objects>

UserManager.cs

using System.Collections.Generic;
using System.Linq;
using Jtx.Domain.Entity;

namespace Jtx.Service.Implement
{
    public class UserInfoManager : GenericManagerBase<User>, IUserManager
    {
        public IList<User> LoadAllByPage(out long total, int page, int rows, string order, string sort)
        {
            ...
        }
        private string HashCode(string key)
        {
            ...
        }

        public override object Save(User entity)
        {
            ...
        }

        public User Get(string account)
        {
            ...
        }

        public User Get(string account, string password)
        {
            ...
        }

        public void Update(User entity, string password)
        {
            ...
        }
    }

}

enter image description here

enter image description here

Web.config

  <!--spring-->
  <spring>
    <parsers>
      <parser type="Spring.Data.Config.DatabaseNamespaceParser, Spring.Data"/>
      <parser type="Spring.Transaction.Config.TxNamespaceParser, Spring.Data"/>
    </parsers>
    <context>
      <!--Dao-->
      <resource uri="assembly://Jtx.Dao/Jtx.Dao.Config/DaoBase.xml" />
      <resource uri="assembly://Jtx.Dao/Jtx.Dao.Config/Dao.xml" />
      <!--Service-->
      <resource uri="assembly://Jtx.Service/Jtx.Service.Config/ServiceBase.xml" />
      <resource uri="assembly://Jtx.Service/Jtx.Service.Config/Service.xml" />
      <!--Web-->
      <resource uri="assembly://Jtx.Web/Jtx.Web.Config/Controllers.xml" />
      <resource uri="config://spring/objects"/>
    </context>
    <objects xmlns="http://www.springframework.net"/>
  </spring>

I’m using spring.net 1.3.2 and NHibernate 3.2 in a asp.net mvc3 project in vs2010.
When I debug, only the <resource uri="assembly://Jtx.Service/Jtx.Service.Config/Service.xml" /> error.When you remove the phrase, then again to debug all ok. But I checked did not find any errors.
At the same time, my reference to CannotLoadObjectTypeException in Spring.net, also found no error.

The problem seems to be a bit messy, I wanted to be as precise as possible and give as much as information that I could.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T17:57:16+00:00Added an answer on June 11, 2026 at 5:57 pm

    The type in service.xml is type="Jtx.Service.Implement.UserManager,Jtx.Service", but the type in usermanager.cs is UserInfoManager. Can you spot the difference:

    xml : Jtx.Service.Implement.UserManager
    code: Jtx.Service.Implement.UserInfoManager
    

    Changing the xml to type="Jtx.Service.Implement.UserInfoManager, Jtx.Service" should do the trick.

    When using spring.net with xml config, these kind of things happen all the time.
    Usually, the first line of the (enormous) exception gives the best hint.
    I had to look for a minute, before I saw the error in your xml.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.