hi,
this error:
Error Number: -2147220978
Error Description: Method 'SendWaitForReply' of object 'IOutMessage' failed
I get when I try to communicate with Navision with MSMQ and Navision Communication Components. I send a XML message...
Option Explicit
Private WithEvents CC2 As NSCOMCOM2Lib.CommunicationComponent
Private DOM As DOMDocument30
Private mobjOutMessage As NSCOMCOM2Lib.OutMessage
Private mlngTimeout As Long
____________________________________________________________
Public Function SendMessageWaitForReply(ByVal Message As String) As Boolean
Dim ok As InMessage
DOM.loadXML Message
DOM.save mobjOutMessage.GetStream()
Set ok = mobjOutMessage.SendWaitForReply(mlngTimeout)
If ok Is Nothing Then
SendMessageWaitForReply = False
Err.Raise vbObjectError + errMessageNotSentNum, "CNASClient", errMessageNotSentDesc
Exit Function
End If
ok.CommitMessage
SendMessageWaitForReply = True
End Function
____________________________________________________________
Can anyone help
Vedran
0
Comments
Set ok = mobjOutMessage.SendWaitForReply(mlngTimeout)
...