|
-
Jan 9th, 2004, 03:48 AM
#1
Thread Starter
Addicted Member
Automation error---[RESOLVED]
I am trying to call a procedure in a dll i have created, there are no errors i can see in the code but at runtime the error:
Runtime error '-2147024770 (8007007e)'
Automation error
The specified module could not be found.
is generated. WHY?
APP Code:
VB Code:
Private WithEvents mobjThread As ThreadProxy.DataSearches
Private Sub cmdNew_Click()
Dim DBPath As String
'On Error GoTo ErrHandler
DBPath = "test"
mobjThread.NewSearch DBPath, 1, True, 20, True
Exit Sub
'ErrHandler:
' MsgBox "Error"
End Sub
Dll Code:
VB Code:
Public Sub NewSearch(ByVal sDBPath As String, ByVal sInt1 As Integer, ByVal sBool1 As Boolean, ByVal sInt2 As Integer, ByVal sBool2 As Boolean)
'do stuff
End Sub
Last edited by mik706; Jan 9th, 2004 at 11:09 AM.
Mik706
-
Jan 9th, 2004, 04:46 AM
#2
mik706
Did you register the dll?
-
Jan 9th, 2004, 04:53 AM
#3
Thread Starter
Addicted Member
-
Jan 9th, 2004, 05:04 AM
#4
mik706
How do you setup you code to call the dll mobjThread? Sets, include it in you project etc...
-
Jan 9th, 2004, 05:10 AM
#5
Thread Starter
Addicted Member
i set the relationship on form load
VB Code:
Private Sub Form_Load()
Set mobjThread = New ThreadProxy.DataSearches
'rest of form load stuff
End Sub
-
Jan 9th, 2004, 05:25 AM
#6
mik706
You referenced the dll in your project?
-
Jan 9th, 2004, 05:31 AM
#7
Thread Starter
Addicted Member
-
Jan 9th, 2004, 07:12 AM
#8
Addicted Member
What operating system are you using to create the executable and setup package ?
I was getting an automation error because one of my controls could not be registered correctly when creating the setup from WinXP.
Try building from Win98SE (clean version). It might work.
--hyperspaced
-
Jan 9th, 2004, 07:21 AM
#9
Thread Starter
Addicted Member
I am using Win2000, no errors have been reported, ether when i built the dll or registered it.
-
Jan 9th, 2004, 11:09 AM
#10
Thread Starter
Addicted Member
Sorry randem and hyperspaced, as hyperspaced suggested the dll hadn’t registered properly even though i could view the objects. I deleted the original and built the file again and all is now well. Thanks for the help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|