Click here to Skip to main content
15,901,373 members
Home / Discussions / Visual Basic
   

Visual Basic

 
Questiongetpixel Pin
Taylor Kobani18-Apr-07 0:06
Taylor Kobani18-Apr-07 0:06 
AnswerRe: getpixel Pin
Dave Kreskowiak18-Apr-07 3:37
mveDave Kreskowiak18-Apr-07 3:37 
GeneralRe: getpixel Pin
Taylor Kobani20-Apr-07 23:37
Taylor Kobani20-Apr-07 23:37 
GeneralRe: getpixel Pin
Dave Kreskowiak21-Apr-07 6:50
mveDave Kreskowiak21-Apr-07 6:50 
GeneralRe: getpixel Pin
Taylor Kobani22-Apr-07 7:04
Taylor Kobani22-Apr-07 7:04 
QuestionBuilding a Modular System Pin
TheFarsider17-Apr-07 23:51
TheFarsider17-Apr-07 23:51 
AnswerRe: Building a Modular System Pin
Dave Kreskowiak18-Apr-07 3:34
mveDave Kreskowiak18-Apr-07 3:34 
AnswerRe: Building a Modular System Pin
TheFarsider18-Apr-07 6:32
TheFarsider18-Apr-07 6:32 
Dave Thanks for the reply.

The Plugin Method is one I did look at but I have managed to find the solution and once I got to the route of it, was really quite simple although admitadly I dont fully understand the solution myself yet.

Thanks to Peter Huang and Terry for hitting a similar problem and providing me the vital clues

Below is my proof of concept code


'#### Application Code ###
Dim ModulePath As String = ".\Modules\"

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim di As New IO.DirectoryInfo(ModulePath)
Dim aryFi As IO.FileInfo() = di.GetFiles("*.dll")
Dim fi As IO.FileInfo

For Each fi In aryFi
dllName = "James"
GetCopyrights(fi.FullName, dllName)
Next
End Sub

Sub GetCopyrights(ByVal dllPath As String, ByVal dllName as String)

Dim oRMS As Object = Nothing
Try
oRMS = Activator.CreateInstanceFrom(dllPath, dllName & ".RMS.Controller").Unwrap()
Catch ex As Exception
Console.WriteLine(ex.ToString())
End Try
If oRMS IsNot Nothing Then
Console.WriteLine (oRMS.Copyright())
End If
oRMS = Nothing
End Sub


'### Sample DLL Code ###

Namespace RMS
Public Interface iController
Function Copyright() As String
End Interface

Public Class Controller
Implements iController
Function Copyright() As String Implements iController.Copyright
Return "James Tutton 2007"
End Function
End Class
End Namespace


The only thing id still like to do is make sure the interfaces are common for both the dll and oRMS . The Overall purpose is building a service that uses a common interface for performing common activities. Sorry for the vagueness of my explanations but I am working under some strict NDA's on the specifics of the project.

--How do you quote on this site??? anyhow
Are these .DLL's being written so that each one is programmed to interact with a specific application??

Yes, the idea is that we build a dll to interact with each third party application we need to intereact with but all the calls and return values are normalised across them by the dlls.
QuestionWith out scroll tab need page...... Pin
Member 387988117-Apr-07 23:50
Member 387988117-Apr-07 23:50 
AnswerRe: With out scroll tab need page...... Pin
Dave Kreskowiak18-Apr-07 3:30
mveDave Kreskowiak18-Apr-07 3:30 
QuestionPrimary key error msg Pin
rrrriiizz17-Apr-07 22:40
rrrriiizz17-Apr-07 22:40 
AnswerRe: Primary key error msg Pin
klaydze17-Apr-07 23:09
klaydze17-Apr-07 23:09 
GeneralRe: Primary key error msg Pin
rrrriiizz19-Apr-07 17:43
rrrriiizz19-Apr-07 17:43 
QuestionChanging a treeview's Node.Checked via code doesn't fire the NodeCheck event Pin
lee2317-Apr-07 21:56
lee2317-Apr-07 21:56 
QuestionTEXT FILE TO JPEG FILE Pin
klaydze17-Apr-07 21:31
klaydze17-Apr-07 21:31 
AnswerRe: TEXT FILE TO JPEG FILE Pin
Christian Graus17-Apr-07 21:49
protectorChristian Graus17-Apr-07 21:49 
QuestionDim vs Var Pin
Cmania17-Apr-07 21:02
Cmania17-Apr-07 21:02 
AnswerRe: Dim vs Var Pin
Amit Sk Sharma18-Apr-07 0:18
Amit Sk Sharma18-Apr-07 0:18 
QuestionSSTAB in VB6.0 Pin
Kumaran21cen17-Apr-07 21:02
Kumaran21cen17-Apr-07 21:02 
AnswerRe: SSTAB in VB6.0 Pin
Dave Kreskowiak18-Apr-07 3:26
mveDave Kreskowiak18-Apr-07 3:26 
Questionhow to debug? Pin
Amit Sk Sharma17-Apr-07 20:56
Amit Sk Sharma17-Apr-07 20:56 
AnswerRe: how to debug? Pin
Christian Graus17-Apr-07 21:51
protectorChristian Graus17-Apr-07 21:51 
GeneralRe: how to debug? Pin
Amit Sk Sharma17-Apr-07 23:03
Amit Sk Sharma17-Apr-07 23:03 
QuestionINET CONTROL Pin
virendra_00717-Apr-07 20:29
virendra_00717-Apr-07 20:29 
AnswerRe: INET CONTROL Pin
Dave Kreskowiak18-Apr-07 3:22
mveDave Kreskowiak18-Apr-07 3:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.