Private Const NERR_Success As Long = 0&
Private Declare Function NetMessageBufferSend Lib "NETAPI32.DLL" _
(yServer As Any, yToName As Byte, yFromName As Any, yMsg As Byte, _
ByVal lSize As Long) As Long
Public Function Sendmsg(strTo As String, strFrom As String, _
strMessage As String) As Boolean
Dim bytTo() As Byte
Dim bytFrom() As Byte
Dim bytMsg() As Byte
bytTo = strTo & vbNullChar
bytName = strFrom & vbNullChar
bytMsg = strMessage & vbNullChar
Sendmsg = (NetMessageBufferSend(ByVal 0&, yToName(0), _
ByVal 0&, yMsg(0), UBound(yMsg)) = NERR_Success)
End Function