Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


Assembly unable to load during windows service installation

Posted on 2007-03-19
Medium Priority
Last Modified: 2013-12-17
I have a windows service created in VB.net and I am trying to create a setup project to install it.  When I run the install program I get the following error message:

Unable to get the installer types in the <...> assembly. --> One or more of the types in the assembly unable to load.

Is there any way to find out which assembly is causing the problem.  The install works fine on another machine.  Can anyone suggest why this might be happening.

Question by:nicksbell
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
LVL 23

Expert Comment

by:Christopher Kile
ID: 18750254
Your assembly module that contains those types is not where you expect it to be.  Check which directory the install thinks it's in, then physically check your system to verify that the assembly is in fact in that location.  If it is, we'll see if we can find something else to check.

Author Comment

ID: 18750435
Well I am not entirely sure I understand what you are saying, my problem (I think) is identifying which 'types' we are talking about.  I have checked all of the dependencies in my setup project and they all point to valid locations for the source files....is that what you meant?
LVL 23

Expert Comment

by:Christopher Kile
ID: 18751115
Not the source files.  At run-time, your source files are just a bunch of text (these aren't VBScript files, after all).  The types are contained in DLLs and EXEs that must be loaded and referenced at runtime.  We also call these "types" CLASSES.
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.


Author Comment

ID: 18751763
Sorry, when I said source files, I meant the orginal references to DLLs in the underlying project....not the 'source' as in code files.  What I meant was that the dependencies shown in the setup project relate to the DLLs that are referenced by the primary output project.  The locations of these DLLs are all valid.

Incidentally, the whole solution, including the setup  project compiles without a problem.  The problem arises when I try to run the setup.exe file.

Author Comment

ID: 18765161
I have run msiexec /l*v from the command line and the area in the log file where the error is is as follows:

MSI (s) (C4:54) [11:32:33:230]: Executing op: FileCopy(SourceName=NEMOS_~4.DLL|nemos_RemoteServer.dll,SourceCabKey=_DF1B5F0694AECA3C6EC2506D8E535827,DestName=nemos_RemoteServer.dll,Attributes=512,FileSize=17920,PerTick=32768,,VerifyMedia=1,,,,,CheckCRC=0,Version=1.0.2636.17472,Language=0,InstallMode=58982400,,,,,,,)
MSI (s) (C4:54) [11:32:33:230]: File: C:\Program Files\FundSolve Ltd\AutoCalcSetup\nemos_RemoteServer.dll;      To be installed;      Won't patch;      No existing file
MSI (s) (C4:54) [11:32:33:230]: Source for file '_DF1B5F0694AECA3C6EC2506D8E535827' is compressed
InstallFiles: File: nemos_RemoteServer.dll,  Directory: C:\Program Files\FundSolve Ltd\AutoCalcSetup\,  Size: 17920
MSI (s) (C4:54) [11:32:33:480]: Note: 1: 2318 2: C:\Program Files\FundSolve Ltd\AutoCalcSetup\nemos_RemoteServer.dll
MSI (s) (C4:54) [11:32:33:902]: Executing op: CacheSizeFlush(,)
MSI (s) (C4:54) [11:32:33:902]: Executing op: InstallProtectedFiles(AllowUI=1)
MSI (s) (C4:54) [11:32:33:902]: Executing op: ActionStart(Name=_42B0858D_0656_415E_A005_6AAD464BF28B.commit,,)
Action 11:32:33: _42B0858D_0656_415E_A005_6AAD464BF28B.commit.
MSI (s) (C4:54) [11:32:33:902]: Executing op: CustomActionSchedule(Action=_42B0858D_0656_415E_A005_6AAD464BF28B.commit,ActionType=1537,Source=BinaryData,Target=ManagedInstall,CustomActionData=/installtype=notransaction /action=commit /LogFile= "C:\Program Files\FundSolve Ltd\AutoCalcSetup\nemos_AutoCalcService.exe" "C:\DOCUME~1\ADMINI~1.DAT\LOCALS~1\Temp\CFG51.tmp")
MSI (s) (C4:54) [11:32:33:902]: Executing op: ActionStart(Name=_4B9E3141_0D84_4D5A_BB6F_4E6AA9B0210F.rollback,,)
Action 11:32:33: _4B9E3141_0D84_4D5A_BB6F_4E6AA9B0210F.rollback.
MSI (s) (C4:54) [11:32:33:902]: Executing op: CustomActionSchedule(Action=_4B9E3141_0D84_4D5A_BB6F_4E6AA9B0210F.rollback,ActionType=1281,Source=BinaryData,Target=ManagedInstall,CustomActionData=/installtype=notransaction /action=rollback /LogFile= "C:\Program Files\FundSolve Ltd\AutoCalcSetup\nemos_AutoCalcService.exe" "C:\DOCUME~1\ADMINI~1.DAT\LOCALS~1\Temp\CFG51.tmp")
MSI (s) (C4:54) [11:32:33:902]: Executing op: ActionStart(Name=_97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install,,)
Action 11:32:33: _97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install.
MSI (s) (C4:54) [11:32:33:902]: Executing op: CustomActionSchedule(Action=_97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install,ActionType=1025,Source=BinaryData,Target=ManagedInstall,CustomActionData=/installtype=notransaction /action=install /LogFile= "C:\Program Files\FundSolve Ltd\AutoCalcSetup\nemos_AutoCalcService.exe" "C:\DOCUME~1\ADMINI~1.DAT\LOCALS~1\Temp\CFG51.tmp")
MSI (s) (C4:68) [11:32:33:933]: Invoking remote custom action. DLL: C:\WINDOWS\Installer\MSI2B.tmp, Entrypoint: ManagedInstall
MSI (s) (C4!80) [11:32:34:542]: Note: 1: 2262 2: Error 3: -2147287038
MSI (c) (48:DC) [11:32:34:542]: Note: 1: 2262 2: Error 3: -2147287038
DEBUG: Error 2835:  The control ErrorIcon was not found on dialog ErrorDialog
The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2835. The arguments are: ErrorIcon, ErrorDialog,
Error 1001. Unable to get installer types in the c:\program files\fundsolve ltd\autocalcsetup\nemos_autocalcservice.exe assembly. --> One or more of the types in the assembly unable to load.
MSI (s) (C4!80) [11:32:39:308]: Note: 1: 2262 2: Error 3: -2147287038
MSI (s) (C4!80) [11:32:39:308]:
MSI (s) (C4:68) [11:32:39:308]: Leaked MSIHANDLE (26) of type 790531 for thread 4736
MSI (s) (C4:68) [11:32:39:308]: Note: 1: 2769 2: _97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install 3: 1
MSI (s) (C4:68) [11:32:39:308]: Note: 1: 2262 2: Error 3: -2147287038
DEBUG: Error 2769:  Custom Action _97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install did not close 1 MSIHANDLEs.
The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2769. The arguments are: _97B9AA6E_40BD_4A59_8184_ED44B8A3820F.install, 1,
Action ended 11:32:39: InstallFinalize. Return value 3.
MSI (s) (C4:54) [11:32:39:323]: User policy value 'DisableRollback' is 0
MSI (s) (C4:54) [11:32:39:323]: Machine policy value 'DisableRollback' is 0
MSI (s) (C4:54) [11:32:39:323]: Executing op: Header(Signature=1397708873,Version=301,Timestamp=913660945,LangId=1033,Platform=0,ScriptType=2,ScriptMajorVersion=21,ScriptMinorVersion=4,ScriptAttributes=0)
MSI (s) (C4:54) [11:32:39:323]: Executing op: DialogInfo(Type=0,Argument=1033)
MSI (s) (C4:54) [11:32:39:323]: Executing op: DialogInfo(Type=1,Argument=AutoCalcSetup)
MSI (s) (C4:54) [11:32:39:323]: Executing op: RollbackInfo(,RollbackAction=Rollback,RollbackDescription=Rolling back action:,RollbackTemplate=[1],CleanupAction=RollbackCleanup,CleanupDescription=Removing backup files,CleanupTemplate=File: [1])
Action 11:32:39: Rollback. Rolling back action:

Does this mean anything to you?  Is it possible to identify what the problem is from this.
LVL 23

Expert Comment

by:Christopher Kile
ID: 18765209
What this is telling me is that AutoCalcService.Exe has a dialog in it called ErrorDialog that uses an object type of ErrorIcon that is not available in the .EXE.  It could be a bad name, or it could be that ErrorIcon is a resource that is contained in another DLL or EXE that isn't yet installed (it may be getting installed as a later part of the process).

Does any of this ring any bells with you?  I'm assuming you developed the AutoCalcService.EXE and that you know where and what the ErrorDialog is.

Author Comment

ID: 18765437
Unfortunately not.  There is no reference at all to ErrorDialog or ErrorIcon in any of my code.  The strange thing is this install works on 2 other machines without a problem.  I have tried reinstalling both the .Net Framwork as well as Visual Studio in case some assemblies had got corrupted but to no avail.  I'm really stumped.
LVL 23

Accepted Solution

Christopher Kile earned 2000 total points
ID: 18765913
OK, I figured something out with some research.  The ErrorDialog and ErrorIcon errors are spurious, they simply mean that an error occurred.  The real error was in a custom installation step that is being handled by a routine called ManagedInstall.  Two errors occurred, in fact.  I have no idea what they are since it is your custom installation step, but you may want to debug it very carefully on this new machine.

Author Comment

ID: 18766117
So I removed all references from AutoCalcService.exe and commented out the code that relied on those reference and then added them back one by one until I found the reference that was causing the problem.  Once I found the offending reference I commented out all of the code that depended on that reference and reintroduced the code bit by bit until I found the specific piece of code that was causing the problem.

The unfortunate thing is that the offending piece of code compiles without a problem and debugs in the development environment without a problem....its just when I try to install via the installation package that the error occurs.  The other unfortunate thing is that the reference is to a third party DLL so I guess I now need to get on to them to see if they can suggest a reason why.

Anyway, thanks a lot for your help.  You can have the points for trying.

Featured Post

Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Welcome my friends to the second instalment and follow-up to our Minify and Concatenate Your Scripts and Stylesheets (http://www.experts-exchange.com/Programming/Languages/.NET/ASP.NET/A_4334-Minify-and-Concatenate-Your-Scripts-and-Stylesheets.html)…
This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question