Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Extra Errors

Status
Not open for further replies.

InsaneProgrammer

Programmer
Jan 17, 2001
44
US
I have some code in an Access 97 database that performs a screen scrap and populates a form. All of a sudden the code has stopped working. Nothing was changed. The code compiles fine but when it runs I get the following error:
"The specified module could not be found."

After I select OK I get Run-time error -2147221231 (80040111):
Automation error
ClassFactory cannot supply requested class.

If I select debug it shows that the error occurs where the
object is initially created. The code on that line is:
Set MySystem = CreateObject("EXTRA.System")

Below is all the code. This is the standard code I use for all my programs. It has worked correctly for years.

Option Compare Database
Option Explicit

Dim HostSettleTime As Integer
Dim iXSuccess As Integer
Dim MySystem As Object
Dim MySessions As Object
Dim MySession As Object
Dim MyScreen As Object
Dim RetValue As Boolean

Function GetExtraSession()


'create a system object
Set MySystem = CreateObject("EXTRA.System")
If (MySystem Is Nothing) Then
Beep
MsgBox "Could not create the EXTRA System object."
Stop
End If

'create a sessions object
Set MySessions = MySystem.Sessions
If (MySessions Is Nothing) Then
Beep
MsgBox "Could not create the Sessions collection object."
End
End If

'set session object
Set MySession = MySystem.ActiveSession
If (MySession Is Nothing) Then
Beep
MsgBox "Could not create the Session object."
End
End If
'checks to see that the session is visible
If Not MySession.Visible Then MySession.Visible = True

'create the screen object and make sure it is a valid object
Set MyScreen = MySession.Screen
If (MyScreen Is Nothing) Then
Beep
MsgBox "Could not create the Screen object."
End
Else
'MsgBox "Session Objects created."
iXSuccess = 1
'MySession.WindowState = wdWindowStateMaximize
End If

End Function

Any help would be greatly appreciated.

 
Its also happen to me. I guest you change your windows become Windows XP. There's problem on install process, Attachmate could not succesfully added path into autoexec.bat, so it complaining about "module not found".

I found it by accident, after long time searching internet, reading documentation, OLE and found nothing ...
finally I just wondering if this just a path problem.
After adding path of your Attachmate to PATH environment, its work.

Use this step to add the path :
1. On "My Computer" right click
2. Click "properties"
3. Click "Advanced" tab
4. Click "Environment Variables"
5. Then add your attachmate directory
(usually "c:\program files\e!pc" into PATH environment

Hope it help

Wassalam
-=bdnt=-
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top