473,769 Members | 4,052 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Windows Service FilenotFound exception when accessing a type from an assemble

I have a class library used by a windows service executable, both
binaries and dependancies are in one bin directory located on c:.

1) I can run a test app on my class library without failure
2) My service runs, but if I reference anything in the class library it
fails with a FileNotFound exception e.g. MyClassLib.MyCl ass A = null;
will cause the exception
3) my service runs under the system account
4) using Window XP SP2
5) My class library is a C++.Net Assembly that wrapps a number of
unmanaged MFC and Win32 DLLs that are in my bin directory.
6) If I call System.Reflecti on.Assembly.Loa dFile from within the
service my class library loads ok.

Any ideas as to how I might solve this one?

Nov 20 '06 #1
1 1423
Got fuslogvw.exe to work by setting up a custon log path. Unfornatley
it didn't help much as all binding where successful.

Vadym Stetsyak wrote:
Hello, ropo!

you can use fuslogvw.exe to see where your service look for the assembly.

See ( http://msdn2.microsoft.com/en-us/yx7xezcf.aspx ) for reference,
how CLR locates assemblies

rI have a class library used by a windows service executable, both
rbinaries and dependancies are in one bin directory located on c:.

r1) I can run a test app on my class library without failure
r2) My service runs, but if I reference anything in the class library
rit
rfails with a FileNotFound exception e.g. MyClassLib.MyCl ass A = null;
rwill cause the exception
r3) my service runs under the system account
r4) using Window XP SP2
r5) My class library is a C++.Net Assembly that wrapps a number of
runmanaged MFC and Win32 DLLs that are in my bin directory.
r6) If I call System.Reflecti on.Assembly.Loa dFile from within the
rservice my class library loads ok.

rAny ideas as to how I might solve this one?
--
Regards, Vadym Stetsyak
www: http://vadmyst.blogspot.com
Nov 21 '06 #2

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

Similar topics

1
394
by: Tom | last post by:
I load an assembly via Assembly assembly=Assembly.LoadFile(assemblyName); .... foreach(Type t in types) { attribs=t.GetCustomAttributes(typeof(MayaPanelAttribute),true); }
2
2227
by: AZSEEK | last post by:
I created a Windows Service in VB.Net and I tried using the InstallUtil and I keep getting this error message -- please help Exception occurred while initializing the installation: system.io.filenotfoundexception: file or assemble name emailpooler.exe, or one of its dependencies, was not found..
12
8501
by: SJD | last post by:
I've just read Christoph Schittko's article on XmlSerializer: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnxmlnet/html/trblshtxsd.asp . . . and very informative it is too. I, too, am getting nasty FileNotFound exceptions. I've read, and digested the article, and I think I've found a bug -- it's difficult to track, though it does happen often.
2
2126
by: Roman Muntyanu | last post by:
Hi All, I got exception when call Activator.GetObject( ... ) When I start my application I register Channel to communicate between two computers and register type ReceiverLocator for remoting in Bind() Then when I need to get reference to this object on remote computer I call Lookup and get proxy from remote computer. Lookup() works fine when I start MyApplication.exe from current
3
7678
by: Jim Lewis | last post by:
I have read several things that state accessing a Web Service through a Query String should work. However, when I try to execute http://localhost/webservice1/service1.asmx/HelloWorld I get the error below. Can I access a Web Service through a Query Sting. I need to send XML to a Flash movie using a Web Service. Thank You, Jim Lewis Server Error in '/WebService1' Application.
3
5006
by: Olivier BESSON | last post by:
Hello, I have a web service of my own on a server (vb.net). I must declare it with SoapRpcMethod to be used with JAVA. This is a simple exemple method of my vb source : >************************************************************************ > <WebMethod(), System.Web.Services.Protocols.SoapRpcMethod()> _ > Public Function HelloWorld() As > <System.Xml.Serialization.SoapElementAttribute("return")> String
12
6531
by: Noam | last post by:
I had originally written a program as a c# console application. The program used a reference that I wrote in c++. Later I was told to re-write the application as a windows service. When the service would start up, as soon as it accessed the reference (by instantiating a class within the reference), the service would crash. In the event viewer I saw that it throw a System.IO.FileNotFoundException saying that the c++ reference was missing...
1
1265
by: serge calderara | last post by:
Dear all, I have build a windows service whcih read soime remote configuration in an application file. That file path is pass as argument in the satrt parameter of the service. If I start the service without any config file related, it start fine but as long as I ask for reading a configuration file it fail to start. Error message displayed under event logger say that FileNotFound exception
1
1956
by: Mahesh Devjibhai Dhola | last post by:
Hi, Scenario: The webservice was developed on windows 2000 Pro and deployed previously on windows XP pro for testing. We have tested for many days. The client for that service was 30+ and accessing the webservice each min. It was working 100% fine. Problem: But now in actual deployment, we have deployed webservice in Win Server 2003 and we have used all the default configurations. Now the clients are accessing that service the same way...
0
9589
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
9423
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10049
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
9996
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
9865
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
6674
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
5447
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3964
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
2
3564
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.