|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Reference to a DLL on the networkHi,
I would like to know if is possible to reference a DLL placing on a network but without to copy the DLL into the bin folder? Thank you very much! Cheers, BlackSun On 3/25/2010 9:48 AM, BlackSun wrote:
> Hi, I believe the only way you could do this is via Assembly.Load() and > I would like to know if is possible to reference a DLL placing on a > network but without to copy the DLL into the bin folder? > > Thank you very much! > > Cheers, > BlackSun similarly named approaches, and using reflection to instantiate classes. I've got to ask, what is the perceived benefit to you by forcing this requirement? -- Mike On 2010-03-25, BlackSun <black_***@email.it> wrote:
> Hi, Well, as long as you can read the dll, then sure. I have some dynamic> I would like to know if is possible to reference a DLL placing on a > network but without to copy the DLL into the bin folder? > > Thank you very much! > > Cheers, > BlackSun validation dlls that I load from the db. The idea is basically, read the dll file into a byte array and then call assembly.load with the byte array. So, I would do something like this for a dll... Dim dllData() As Byte = File.ReadAllBytes("pathtodll") Dim dllAssembly As Assembly = Assembly.Load (dllData) once you have that assembly reference, you can laod types out of it etc. for instance, I have a dll that defines common interfaces/base classes that are referenced by the individual validator dlls and the parent assembly - that way there is a known means of communication (Air-Code)... Dim validator As FAValidatorBase = TryCast (dllAssembly.CreateInstance (validatorInfo.ClassName), FAValidatorBase) If validator Is Nothing Then Throw New FAValidatorLoadException(validatorInfo.ClassName) Dim validationResults As FAValidationResults = validator.PerformValidation(inputData) So, the question is do you have access to the dll's data and can you read it into a byte array :) -- Tom Shelton
Insert Record in DataContext without upgrading the database
Context Menus combobox compiled on visual studio 2003 on windows XP, want to install on windows 7, error Can anyone recommend a print contol library please? Configure Properties of Windows User (Terminal Server Eviroment) issue of assigning a double variable in .net. Can be done? How to read commandtext after added parameters? Grid component. |
|||||||||||||||||||||||