See the Object API Message.Move() method to move a message to a destination folder. You can only move the message from the owner Folder.Messages collection. If you don’t have access to the folder object of the message then you need to get the message object using the Account.GetMessage(messageid) method and use the EnclosingFolders properties to get the owner folder.
The sample code below move the selected message from the Mailbox folder to Cabinet.
set oMsg = client.clientstate.commandmessage
call groupwise.account.mailbox.messages.move(oMsg.messageid, groupwise.account.cabinet.messages)
set oMsg = nothing
Seems like the Messages.Remove() method do not work if you use the Move method. Interesting to see, the Move method create a link for the Sent items messages. May be the index of the messages collection not refresh once the Move method called. You can use the Message.Delete() method to remove the message. See the sample code below:
set oMsg = client.clientstate.commandmessage
call groupwise.account.SentItems.messages.move(oMsg.messageid, groupwise.account.cabinet.messages)
oMsg.delete
set oMsg = nothing