How would I do this via a dll made in VB6???
ok? What do you mean?
this dll would have to be loaded into another vb6 program (since vb6 are ActiveX dlls) and then a sub in the dll would have to be called by the loading program. Loading a dll can be done by using the CreateObject() function in VB.
Shell(), exec()
basically I want when the dll is loaded to execute files, kinda like in just a standard exe it would be something like this
Quote
Private Sub Form_Load()
Shell("notepad.exe"
End Sub
edit:
would this have to be made in something like c,c++, or c# by any chance?
no
Quote from: Clan CDH on December 01, 2006, 10:15 PM
basically I want when the dll is loaded to execute files, kinda like in just a standard exe it would be something like this
Quote
Private Sub Form_Load()
Shell("notepad.exe"
End Sub
edit:
would this have to be made in something like c,c++, or c# by any chance?
Program:
Public Sub Form_Load()
' create the DLL object here
Call dllReference.ExecuteProgram("C:\Windows\sol.exe")
End Sub
DLL:
Public Sub ExecuteProgram(Path as String)
Shell Path
End Sub
Untested. I don't have VB handy.
I talked to him on AIM and it looked like he wanted to execute a by itself .dll as if it was a .exe =/
Calling LoadLibrary executes DllMain, if present.
You can use Windows' rundll to execute a DLL as an executable.
i hope his not making some client server program o.O