473,785 Members | 2,266 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

System.TypeInit ializationExcep tion

Hello,
We have encountered a System.TypeInit ializationExcep tion in our
product. This exception occurs while closing the application when
application called excel.Quit(). excel is an Excel.Applicati onClass
object. The application was unable to load
'Microsoft.Offi ce.Interop.Exce l' file.
Following the pre-bind state information:

=== Pre-bind state information ===
LOG: DisplayName = Microsoft.Offic e.Interop.Excel , Version=10.0.45 04.0,
Culture=neutral , PublicKeyToken= 31bf3856ad364e3 5
(Fully-specified)
LOG: Appbase = C:\Program Files\Kolachi Advanced Technologies\XT reme -
Trader Interface\
LOG: Initial PrivatePath = NULL
Calling assembly : Common, Version=2.2.0.3 , Culture=neutral ,
PublicKeyToken= null.
===

LOG: Publisher policy file is not found.
LOG: Host configuration file not found.
LOG: Using machine configuration file from
C:\WINDOWS\Micr osoft.NET\Frame work\v1.1.4322\ config\machine. config.
LOG: Post-policy reference: Microsoft.Offic e.Interop.Excel ,
Version=10.0.45 04.0, Culture=neutral , PublicKeyToken= 31bf3856ad364e3 5
LOG: Attempting download of new URL file:///C:/Program Files/Kolachi
Advanced Technologies/XTreme - Trader
Interface/Microsoft.Offic e.Interop.Excel .DLL.

I am unable to understand why did this happen, Especially when the
application was closing. Any thoughts about it?

Maqsood Ahmed [MCP C#,SQL Server]
Kolachi Advanced Technologies
http://www.kolachi.net

*** Sent via Developersdex http://www.developersdex.com ***
Nov 17 '05 #1
1 4042
Maqsood,

Just curious, instead of using your own interop wrapper, why not use the
Primary Interop Assemblies offered by Microsoft? You will probably have
less problems with that.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"Maqsood Ahmed" <ma***********@ gmail.com> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
Hello,
We have encountered a System.TypeInit ializationExcep tion in our
product. This exception occurs while closing the application when
application called excel.Quit(). excel is an Excel.Applicati onClass
object. The application was unable to load
'Microsoft.Offi ce.Interop.Exce l' file.
Following the pre-bind state information:

=== Pre-bind state information ===
LOG: DisplayName = Microsoft.Offic e.Interop.Excel , Version=10.0.45 04.0,
Culture=neutral , PublicKeyToken= 31bf3856ad364e3 5
(Fully-specified)
LOG: Appbase = C:\Program Files\Kolachi Advanced Technologies\XT reme -
Trader Interface\
LOG: Initial PrivatePath = NULL
Calling assembly : Common, Version=2.2.0.3 , Culture=neutral ,
PublicKeyToken= null.
===

LOG: Publisher policy file is not found.
LOG: Host configuration file not found.
LOG: Using machine configuration file from
C:\WINDOWS\Micr osoft.NET\Frame work\v1.1.4322\ config\machine. config.
LOG: Post-policy reference: Microsoft.Offic e.Interop.Excel ,
Version=10.0.45 04.0, Culture=neutral , PublicKeyToken= 31bf3856ad364e3 5
LOG: Attempting download of new URL file:///C:/Program Files/Kolachi
Advanced Technologies/XTreme - Trader
Interface/Microsoft.Offic e.Interop.Excel .DLL.

I am unable to understand why did this happen, Especially when the
application was closing. Any thoughts about it?

Maqsood Ahmed [MCP C#,SQL Server]
Kolachi Advanced Technologies
http://www.kolachi.net

*** Sent via Developersdex http://www.developersdex.com ***

Nov 17 '05 #2

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

Similar topics

1
6397
by: Ethan | last post by:
I made a program that works fine as long as its on my machine, but as soon as i move it to a network drive it stops working. I'm still trying to run it on my machine just from a network drive and it gives me system.typeinitializationexception. Anyone know what changes when i move it to a network drive and try running it from there? I have also tried running it on a machine with .net
2
14045
by: Paul Gronka | last post by:
I've got a VB.NET windows application (written in VS .NET 2003) that makes a call to WMI for retrieving the MAC Address from the client's PC. It works on 4 out of the 5 PC's tested so far. All the workstations are DELLs running XP SP1a with the 1.1 .NET Framework. The following line of code generates an exception on the one PC: Dim oMac As New System.Management.ManagementClass("Win32_NetworkAdapterConfiguration") The error it...
1
2270
by: sys | last post by:
I made a smart client that I purposed to offer on a web server. But when I try to run it by dint of Internet Explorer, I get the System.TypeInitializationException in the IEExec.exe thread. My exe is signed and has full trust on my computer. And when I start the programm directly (C:\Inetpub\myfolder\sample.exe) it works fine. Has somebody an idea?
0
1651
by: Sagaert Johan | last post by:
this code using System; using System.Net.Sockets; namespace ConsoleApplication1 { /// <summary> /// Summary description for Class1. /// </summary>
3
23105
by: nick | last post by:
The program runs well on Local harddisk. But it always popup the exception if I run it on Netware mapping disk. After debugger say there is no source code on the exception. Also the following error shows. Very strange. Unhandled Exception: System.TypeInitializationException: The type initializer fo r "handnetconsole.Monitor" threw an exception. ---> System.Security.SecurityExce ption: Request failed.
0
1497
by: user | last post by:
After starting a Windows Forms Application developed with VS 2005 Prof Beta 2, built in "Release" mode, I get "An unhandled exception of type 'System.TypeInitializationException' " When buildung in "Debug" mode, the application runs fine. Can anybody tell me whats wrong? Thanks
0
419
by: MJ | last post by:
I have an application that I am test deploying to others in my company. The application runs fine in the IDE as well as from the exe on my PC. However, when I install the program on another PC I get the following error when I try to run it: An unhandled exception of type 'System.TypeInitializationException' occurred in Unknown Module. Additional information: The type initializer for "WindowsApplication.MainModule" threw an exception ...
3
3711
by: linaj | last post by:
Hi, I have singleton class in C#: class Logger { static Logger lInstance = new Logger(); private Logger() {}
0
601
by: =?Utf-8?B?TWFyY3VzIFNjaGFlZmVy?= | last post by:
Hi everybody, I'm working on my application for appr. 2 years and now suddenly I got an System.TypeInitializationException in one of my global modules. The error is thrown at the first call of a subroutine out this module. The code I was programming isn't related in any way with this module and I even hadn't loaded this module into the dev. enviroment the first time the error occured.
0
9647
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10162
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10100
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9959
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8988
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6744
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5396
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5528
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4061
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.