473,387 Members | 1,464 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,387 software developers and data experts.

plugin architecture with c#/.net dlls

I'm trying to write an application that takes plugins. I'd like to be
able to drop a dll into my apps directory and have the app see it on
loading (easy to do) then load the dll and interogate it to see if it
has a particular class or interface is implemented. If so I'll call
it etc.

My question is: Given that I have an interface defined
(MyPluginInterface) how do I go about taking a strange dll and
interogating it to see if it supports it then instance that
class/interface.

any help would be greatly appreciated.

thanks
Nov 15 '05 #1
3 3685
You are in luck, my first article on plug-ins examines all of the methods for
interrogating
a library for plug-ins to load. You can view it on my blog at the below link.
To answer
the obvious questions, I'll definitely be keeping this code up to date, and I
have a couple
more articles on the platter just about ready to go out that discuss concepts
further into
the plug-in architecture. My main block at this time, is an extremely stringent
set of design
goals that I'm writing about in a kind of pre-amble document describing my end
goals. I
should be done with the goal document this weekend, and maybe Part 2 where I'll
show
all of the various methods for actually loading and working with plug-in types.

http://weblogs.asp.net/justin_rogers...les/61042.aspx
--
Justin Rogers
DigiTec Web Consultants, LLC.
Blog: http://weblogs.asp.net/justin_rogers
"Allen Anderson" <al***@sparkysystems.com> wrote in message
news:9v********************************@4ax.com...
I'm trying to write an application that takes plugins. I'd like to be
able to drop a dll into my apps directory and have the app see it on
loading (easy to do) then load the dll and interogate it to see if it
has a particular class or interface is implemented. If so I'll call
it etc.

My question is: Given that I have an interface defined
(MyPluginInterface) how do I go about taking a strange dll and
interogating it to see if it supports it then instance that
class/interface.

any help would be greatly appreciated.

thanks

Nov 15 '05 #2
excellent work man, thanks!

On Fri, 6 Feb 2004 15:45:27 -0800, "Justin Rogers"
<Ju****@games4dotnet.com> wrote:
You are in luck, my first article on plug-ins examines all of the methods for
interrogating
a library for plug-ins to load. You can view it on my blog at the below link.
To answer
the obvious questions, I'll definitely be keeping this code up to date, and I
have a couple
more articles on the platter just about ready to go out that discuss concepts
further into
the plug-in architecture. My main block at this time, is an extremely stringent
set of design
goals that I'm writing about in a kind of pre-amble document describing my end
goals. I
should be done with the goal document this weekend, and maybe Part 2 where I'll
show
all of the various methods for actually loading and working with plug-in types.

http://weblogs.asp.net/justin_rogers...les/61042.aspx


Nov 15 '05 #3

Hi Allen,

I am glad you got what you want.

If you have further concern, please feel free to post, we will help you.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #4

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

Similar topics

4
by: Aaron Queenan | last post by:
COM has many facilities to assist with creating an application with Plugin support, for example, component categories to determine what components to load, the OLE specification and interfaces to...
1
by: Bruce Vander Werf | last post by:
Our current unmanaged architecture consists of an EXE and several optional DLLs. The list of available DLLs is stored outside of the EXE, and the DLLs are loaded as needed. The DLLs have identical...
2
by: Chua Wen Ching | last post by:
Hi there, I had some doubts on creatings plugins. As most example on the internet shows how to write plugins onto a plugin host which is normally a windows form program. 1) Can i replace...
5
by: Tamir Khason | last post by:
Friends, maybe someone knows good references for .NET plugin based program architecture. E.g I want to be able to "put" class library(dll) in some place (where I do not the name of the class, but...
2
by: Matt | last post by:
I'm hoping someone can steer me in the right direction to try to do the following: I am developing an application where we receive files from customers. Right now we receive a variety of...
3
by: CSharpNewBie | last post by:
Hi I am looking to create a Plugin Architecture. I looked at this extend or enhance the User Interface (UI) article http://www.codeproject.com/csharp/extensibleui.asp and It looks good and I...
1
by: Craig Buchanan | last post by:
I am building an application to help researcher record the outcomes of their studies. These outcomes are document across a number of paper forms. The information documented on these forms varies...
4
by: anglozaxxon | last post by:
I'm making a program that consists of a main engine + plugins. Both are in Python. My question is, how do I go about importing arbitrary code and have it be able to use the engine's functions,...
1
by: Olie | last post by:
I was quite surprised to find virtually nothing about this but I may have been searching for the wrong thing. I want to know the best way to provide a programming interface to a plugin. I...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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...
0
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,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.