Dynamically load the dll's on user's selection

Hi ,  

I am in a need to load the dll's dynamically ,based on user's selection and get them added to the References of Solution Explorer in the application(VS 2008,c#) .How can I proceed with this requirement?

 Any pointers to this would be of great  help. Thanks in advance.


 

0
Pratibha_Pillai
1/7/2009 11:50:05 AM
asp.net.getting-started 91979 articles. 3 followers. Follow

5 Replies
422 Views

Similar Articles

[PageSpeed] 51

You can use System.Reflection.Assembly.Load().

Hope it helps.


Jef Claes
~~~~~~~~~~

Visit my blog
0
Nemesis116
1/7/2009 12:01:05 PM

Pratibha_Pillai:
Hi , 

I am in a need to load the dll's dynamically ,based on user's selection and get them added to the References of Solution Explorer in the application(VS 2008,c#) .How can I proceed with this requirement?

 Any pointers to this would be of great  help. Thanks in advance.

 

Is this for a web application or a windows application?

If it's for a web application, it's not going to happen - the source isn't probably even on the server - and why do you need references added to your solution based on what a user selects? If the user CAN use a reference, then it should be there anyway, and doesn't cost anything to be there anyway.

If it's for a windows application, the same really applies, you supply them the compiled binaries, not the solution/source files - and again there's no need to dynamically add references to your solution based on what a user selects in the application.

Perhaps if you can state WHY you think you need to do this, some kind soul can give you some pointers as to the correct solution.

0
Mr
1/7/2009 12:16:03 PM

Mr^B:

Pratibha_Pillai:
Hi , 

I am in a need to load the dll's dynamically ,based on user's selection and get them added to the References of Solution Explorer in the application(VS 2008,c#) .How can I proceed with this requirement?

 Any pointers to this would be of great  help. Thanks in advance.

 

Is this for a web application or a windows application?

If it's for a web application, it's not going to happen - the source isn't probably even on the server - and why do you need references added to your solution based on what a user selects? If the user CAN use a reference, then it should be there anyway, and doesn't cost anything to be there anyway.

If it's for a windows application, the same really applies, you supply them the compiled binaries, not the solution/source files - and again there's no need to dynamically add references to your solution based on what a user selects in the application.

Perhaps if you can state WHY you think you need to do this, some kind soul can give you some pointers as to the correct solution.

 

 

That's exactly what I thought. But I googled and found that solution. I also doubt it would be a good solution, it might be possible though.


Jef Claes
~~~~~~~~~~

Visit my blog
0
Nemesis116
1/7/2009 12:32:14 PM

Nemesis116:

That's exactly what I thought. But I googled and found that solution. I also doubt it would be a good solution, it might be possible though.

 

That will load the dll dynamically for sure, that's what reflection is all about.

It's the "added to the References of Solution Explorer" I have issues with...

How do you like a deployed product back to its source - I use source control, should it update it there? Should it update my local copy, what about the rest of the team?

If it's not in the references, it won't be deployed anyway, he's asking for a user selection within the deployed app. effectively to recompile and redeploy itself - and that's just plain daft!

Smile

0
Mr
1/7/2009 12:43:58 PM

Thanks for the reply.

I would like to elaborate on my requirement : It is a windows application.

I am using a template to place the application under Visual C#.When i want to create a new application I select the template under

Visual C# ,which will in turn prompt a CustomWizard through which the user can enter the parameters required for the

application.In addition the users are given the provision to select the dll's which needs to be added to the new application(which

will be created).

I wanted to know if it is possible to get the selected dll's been added to the References of the Solution Explorer of the new

application programatically ?(as how we can otherwise add dll's manually  using AddReferences and later use them).So that

when the new application is been created we want the selected dll's to be seen under the References.

0
Pratibha_Pillai
1/16/2009 4:27:13 AM
Reply:

Web resources about - Dynamically load the dll's on user's selection - asp.net.getting-started

iPhone 5 A6 chip to dynamically up-clock up to 1.3GHz (and downclock too)?
Interesting video from our friends at TLDToday: If this is not just a Geekbench app glitch, it could indicate why that A6 processor is so 2X ...

Apple's Lightning port dynamically assigns pins to allow for reversible use
... a closer look at how Apple's new Lightning connector works, and has come to the conclusion that the 8 pins on each side of the plug are dynamically ...

iPhone 5 Lightning port dynamically reassigns pins
... of Apple's Lightning USB cable shows that the pins on the plug aren't arranged symmetrically, suggesting that the Lightning port can dynamically ...

Urlbox Launches Screenshots-as-a-Service Platform to Dynamically Update Galleries
... changes. Launched yesterday, Urlbox allows anyone with a gallery displaying website screenshots to automate the process and keep them dynamically ...

Everything.me launcher dynamically adapts to what you’re doing right now
... phone according to what you’re doing. Perform a search for ‘football’ and your background will change to the NFL logo. A launcher that dynamically ...


A YouTube Experiment Resizes the Player Dynamically
There's a new YouTube experiment that changes the video player's size, depending on the browser window's size. When resizing Chrome's window, ...

Apple Granted “Dynamically Changing Cursor for User Interface” Patent, Originally Filed in 2003
... a utility patent that covers the use of the mouse cursor that changes according to the context of the task it is engaged in. Called a “Dynamically ...

Atmel's FPSLIC II Dynamically Reconfigurable SoC Supports "Silicon-Sharing" For Peripherals & Interfaces ...
Silicon-Sharing Fits 200K Gate Design into 40K Gate FPSLIC II's, Cuts Power Drain by 97%

Everything.me Launcher Wants to Dynamically Change Phones Based on Location, Interests, and Mental State ...
What if your phone’s launcher dynamically changed based upon interests, your location, or topics you had in mind at a specific moment? A new ...

Resources last updated: 1/1/2016 2:55:58 AM