[AccessD] Run Time Error 48. Fail To Load DLL.

Jim Lawrence (AccessD) accessd at shaw.ca
Fri Aug 29 14:19:21 CDT 2003


Run Time Error 48. Fail To Load DLL.Hi Michael:

Is the Outlook module installed or registered, in Access, on the offending
machine?

Jim
  -----Original Message-----
  From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Millaud, Michael J
[ITS]
  Sent: Friday, August 29, 2003 10:59 AM
  To: accessd at databaseadvisors.com
  Subject: [AccessD] Run Time Error 48. Fail To Load DLL.


  Hey All,

  I recently down graded an XP Database to Access2k to avoid the cost and
hassle of installing XP or a 97 Database in a new group of users machines.
As expected of the 20+ users One receives the RunTime Error 48 Fail To Load
DLL.  I have relaoded Access2k thinking an Access DLL was bad but did not
help.  I transferred a couple the Outlook MSOUTL09.OLB that works for me and
removed the reference that was used referenced this one instead, again to no
avail.  Is there something else I should look into?  The debug drops errors
at line:   Set myOlApp = CreateObject("Outlook.Application") in the
following code.  Again, this works for all but one user so I am at a loss.
Please help.




XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
  Dim Inc As String
  Dim strName As String
  Dim strName2 As String
  Dim stDocName As String
  Dim DB As Database
  Dim RS As Recordset
  Dim strCapture As String
  Dim strSQL As String
  Dim strSaveName As String

  DoCmd.SetWarnings False
      stDocName = "qryMainFilter"
      DoCmd.OpenQuery stDocName, acNormal, acEdit
  DoCmd.SetWarnings True
  Set DB = CurrentDb
  strSQL = "SELECT tblLetterType.Desc FROM tblOutPut LEFT JOIN tblLetterType
ON tblOutPut.LetterType = tblLetterType.LetterTag GROUP BY
tblLetterType.Desc;"

  Set RS = DB.OpenRecordset(strSQL)

  RS.MoveLast
  strCapture = RS.Fields("Desc")

  Inc = Me!txtIncVal
  strName = Me!txtSaveString
  strName2 = "Source" & "_" & strName

  strSaveName = "C:\PCSLetters\Hist\" & strName & "_" & strCapture & "_" &
Inc & ".txt"

      DoCmd.TransferText acExportFixed, "OutPut_Spec", "tblOutPut",
"C:\PCSLetters\Hist\" & strName & "_" & strCapture & "_" & Inc & ".txt"

      DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97,
"tblOutPut", "C:\PCSLetters\Hist\" & strName & "_" & strCapture & "_" & Inc
& ".xls"

  'Hmmm What is this??    DoCmd.TransferSpreadsheet acExport,
acSpreadsheetTypeExcel97, "tblFilter", "C:\PCSLetters\Hist\" & strName2 &
"_" & strCapture & "_" & Inc & ".xls"



  '>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
  '>>> E-Mail Process Below
  '>>>
  '>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
  'Dim StrSendFileName As String
  Dim myOlApp As Outlook.Application
  Dim myItem As Outlook.MailItem
  Dim myAttachments As Variant

  'StrSendFileName = "c:\pcsletters\CreditClasslOutPut.xls"
  Set myOlApp = CreateObject("Outlook.Application")        '<----------
ERROR IS HERE!
  Set myItem = myOlApp.CreateItem(olMailItem)
  Set myAttachments = myItem.Attachments
  myAttachments.Add strSaveName
  With myItem
  .Subject = "PCS A/R Letter Process"
  .Body = "File Saved as " & strSaveName & vbCrLf & "Attached is one of the
PCS A/R Letters files!" & vbCrLf
  .To = "mike.millaud at mail.sprint.com;Roberta.Snyder at mail.sprint.com"
  '.BCC = "whoever at Comp.com"
  '.Attachments = myAttachments
  .Send
  End With
  Set myOlApp = Nothing

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX





  Thanks

  Mike
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030829/11acda04/attachment-0001.html>


More information about the AccessD mailing list