This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal


Mar 26, 2018, 3:39 AM
3 Posts

run-time error '-2147417851 (80010105)'

  • Category: Mail
  • Platform: Windows
  • Release: 9.0
  • Role:
  • Tags:
  • Replies: 2

I wrote this code, which works fine on version 8.5 but not on version 9.0. Any suggestions?

Sub Email_Individually()
Dim NSession As Object
Dim NDatabase As Object
Dim NUIWorkSpace As Object
Dim recepient As String, Copyto As String
Dim NDoc As Object, Username As String, MaildbName As String
Dim NUIdoc As Object
Dim Maildb As Object
Dim j As Long
j = 4
   
   
While (Len(Range("d" & j).Value) > 0)
    'Creates Session
    Set NSession = CreateObject("Notes.NotesSession")
    Set NDatabase = NSession.GETDATABASE("", "")
    If NDatabase.IsOpen = True Then
    Else
        NDatabase.OPENMAIL
    End If
    'Creates New Mail
    Set NDoc = NDatabase.CREATEDOCUMENT
    Set NUIWorkSpace = CreateObject("Notes.NotesUIWorkspace")
    recepient = Worksheets("Email info").Range("c" & j) 'Copies the email
    Copyto = Worksheets("Email info").Range("d" & j)    'Copies the branch mail
   
    With NDoc
        .SendTo = recepient
        .Copyto = Copyto
        .Subject = "à»Ô´ÍèÒ¹ : KIKO,BullP ¨èÒ´͡àºÕé / ¤Ãº¡Ó˹´ / ¤×¹à»ç¹ËØé¹ËÃ×Íà§Ô¹ Çѹ·Õè XX ¡ØÁÀҾѹ¸ì 2561"
   
        'Email body text
       
        Set NotesRichTextItem = .CREATERICHTEXTITEM("Body")
        NotesRichTextItem.APPENDTEXT ("äÎäÅ·ìÊÕà¢ÕÂÇ = Knock out")
        NotesRichTextItem.AddNewline (2)
        NotesRichTextItem.APPENDTEXT ("äÎäÅ·ìÊÕªÁ¾Ù = Knock in")
        NotesRichTextItem.AddNewline (2)
        NotesRichTextItem.APPENDTEXT ("µÑÇÍÑ¡ÉÃÊÕ¿éÒ = ¤Ãº¡Ó˹´ä´éà§Ô¹¤×¹")
        NotesRichTextItem.AddNewline (2)
        NotesRichTextItem.APPENDTEXT ("µÑÇÍÑ¡ÉÃÊÕÊéÁ = ä´éÃѺ¤×¹à»ç¹ËØé¹")
        NotesRichTextItem.AddNewline (2)
      

        .Save True, False
    End With
    Set NUIdoc = NUIWorkSpace.EDITDOCUMENT(True, NDoc) 'To recheck everything, before sending
   
    With NUIdoc
    'Find the marker text in the Body item
        .GoToField ("Body")

       
        Worksheets("Records").Range("a2:l2").Copy
            .Paste
        Worksheets("Records").Range("a" & j, "l" & j).Copy
            .Paste
        Worksheets("Records").Range("m2:x2").Copy
            .Paste
        Worksheets("Records").Range("m" & j, "x" & j).Copy
            .Paste
        Application.CutCopyMode = True

    End With
    j = j + 1
    recepient = ""
    Copyto = ""

Wend

Set NSession = Nothing
Set NDatabase = Nothing
Set Maildb = Nothing
Set NDoc = Nothing
Set NUIdoc = Nothing
Set NUIWorkpSpace = Nothing


End Sub

 

 

 

Mar 26, 2018, 1:27 PM
326 Posts
Try

From a command prompt change the directory to the notes program directory and then issue regsvr32 nlsxbe.dll

 

 

 


This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal