/ Forums / Advansys Formativ / Creating Solutions with Formativ / Error on obtaining CommandMessage / Reply To: Error on obtaining CommandMessage
September 24, 2007 at 4:44 pm
#7883
We could not re-produce the behaviour in here. It may be the GroupWise client or some unknown issue on that user considering the code is working for most of the users. May be you need to run the GWCheck on that user or upgrade the GroupWise client.
You can also place the error handler on the code, so that when it fails to access the message object it prompt the user to some meaningful message. Please see below an example:
Sub Main(Client, GWEvent) dim objMsg if not GetMessage(objMsg, Client) then msgbox "Unable to access the message. Please try again" end if set objMsg = nothing End Sub ' Access the message. function GetMessage(byref abjMsg, Client) on error resume next GetMessage = false set abjMsg = nothing Set abjMsg = Client.ClientState.CommandMessage if not abjMsg is nothing then GetMessage = true end if end function
Regards,
Advansys Support