The DirectPlayMessage.WriteLong method writes a Long to the message data and advances the write pointer.
object.WriteLong(val As Long)
If the method fails, an error is raised and Err.Number will be set.