473,385 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

URGENT : GetTypes in assembly??

dear all,

I am using the GetTypes method of an assembly object in
order to check that it implement a particular needed
interface for my application.

system.Reflexion.Assembly.LoadFrom(sFile).GetTypes was
working fine until today where I get an error saying that
all type in assembly cannot be loaded.

Without changing anything I get this error any idea why
and how can I avoid it?

Thnaks for your information
regards
serge
Jul 21 '05 #1
2 1787
aerge calderara <se*************@maillefer.net> wrote:
I am using the GetTypes method of an assembly object in
order to check that it implement a particular needed
interface for my application.

system.Reflexion.Assembly.LoadFrom(sFile).GetTypes was
working fine until today where I get an error saying that
all type in assembly cannot be loaded.

Without changing anything I get this error any idea why
and how can I avoid it?


Is there any InnerException in the exception thrown by GetTypes()?

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Jul 21 '05 #2
I had a similar problem. In my case i had multiple dlls in the same
folder as dependancies. These were referenced and used in the dll i was
reflecting. I did an Assembly.LoadFrom for each of these files then it
worked. Would have been nice if Assembly.LoadFrom would load the main
dll and all its dependancies but i could not figure out how to make it
do that.

Hope this helps
Leon Lambert

aerge calderara wrote:
dear all,

I am using the GetTypes method of an assembly object in
order to check that it implement a particular needed
interface for my application.

system.Reflexion.Assembly.LoadFrom(sFile).GetTypes was
working fine until today where I get an error saying that
all type in assembly cannot be loaded.

Without changing anything I get this error any idea why
and how can I avoid it?

Thnaks for your information
regards
serge


Jul 21 '05 #3

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

Similar topics

0
by: Stephane Belzile | last post by:
Hi, I have been trying for more than 3 days to load an assembly and execute a method from a specific class. Loading the assembly from the GAC using it's strong name works fine but when I try to...
4
by: Ahmet | last post by:
Hi all; I have one application in which I read form names from database to be opened. I open form with the code below, and call its show method for form to be shown but before this, I must set...
1
by: Abdessamad Belangour | last post by:
Hi all, An assembly is composed of a set of modules. An Assembly and a Module classes have a GetTypes() methods. Moreover, an Assembly class has a GetExportedTypes() method. 1. This means that if...
5
by: RickDee | last post by:
Please help, anybody. I am trying to write a program so that it can launch an exe file ( which is also genereated in C# ) and then simulate the button clicking and invoke the methods inside the...
8
by: Chris | last post by:
Hi, All my websites and webservices are down. I get the following message Server Error in '/mywebservices' Application....
2
by: aerge calderara | last post by:
dear all, I am using the GetTypes method of an assembly object in order to check that it implement a particular needed interface for my application. ...
0
by: tanske | last post by:
Hi, Here's the error I received after browsing the ASMX file from IIS. Server Error in '/ABC' Application. --------------------------------------------------------------------------------...
1
by: Dan Holmes | last post by:
Assembly a = Assembly.LoadFrom(@"c:\sandbox\iaf.net\serverinstall\IVS.WMS.Category.Server.dll"); Type t = a.GetTypes(); The GetTypes fails with this message: "System.TypeLoadException: Could...
5
by: Dan Holmes | last post by:
i have two classes that throw when GetTypes() is executed. The following are their signatures. public sealed class ProductService : IAF.TransactionComponent, IProductService public sealed...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.