Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
richardgiroux1 Absent Member.
Absent Member.
2669 views

Capturing commands in 2012...not working (eGW_CMDID_SEND)

I have a plugin that process email when it is sent (moves the email onto a folder). The plugin works on GW 7 and 8 but fails in 2012. Subsequent testing shows that the existing code to trap events like sending email fails in the 2012 client. To confirm this issue, I created a new test plugin using the GW 2012 APK with the C3POWisard and again found that the plugin does work in GW8 but not 2012. Does anyone know how to trap events like eGW_CMDID_SEND in 2012?
Labels (1)
0 Likes
4 Replies
richardgiroux1 Absent Member.
Absent Member.

Re: Capturing commands in 2012...not working (eGW_CMDID_SEND

RESOLVED!

I contacted Novell and they listed this as a bug but I needed an answer ASAP so I did some more poking around. It turns out this issue was fixed in SP1 for the client. I downloaded SP2 for the client and the issue was resolved.
0 Likes
s_vogel Absent Member.
Absent Member.

Re: Capturing commands in 2012...not working (eGW_CMDID_SEND

Hi Richard!

I am currently working on something like that too. On my end the capturing of the command works quite well (When I open a new mail message and click on the send button). What I want to do is be able to work with the mail that the user attempts to sending. Do you have any functionality like that implemented? How do you get the underlying message object? I wanted to go via ClientState.CommandMessage but this property is empty when working with a new message. Then I thought I could get the latest message from the SENT folder. Therefore you need to work with the GroupWise Object API and not with the C3PO delivered APIs. And it is quite hacky.

Regards Sebastian
0 Likes
s_vogel Absent Member.
Absent Member.

Re: Capturing commands in 2012...not working (eGW_CMDID_SEND

For anyone who is searching for a similar approach here is the kind of hacky, but working solution to the problem of getting the Message Object you want to send: https://gist.github.com/vuchl/34b68f5c81eaa23e6329#file-gwcommand-cs-L138.

You intercept the eGW_CMDID_SEND command call, execute the base command, login in to GroupWise via Object API, get the current account and then the SentItems folder. There you take the last sent message. I did not implement any storage funtionality in this example. You could now use your own logic to implement flat file saving (via ItemSaveMessage() from Token API) or some kind of database storage. I will make a more complete tutorial on that some time later.
0 Likes
Highlighted
s_vogel Absent Member.
Absent Member.

Re: Capturing commands in 2012...not working (eGW_CMDID_SEND

s_vogel;2344281 wrote:
For anyone who is searching for a similar approach here is the kind of hacky, but working solution to the problem of getting the Message Object you want to send: https://gist.github.com/vuchl/34b68f5c81eaa23e6329#file-gwcommand-cs-L138.

You intercept the eGW_CMDID_SEND command call, execute the base command, login in to GroupWise via Object API, get the current account and then the SentItems folder. There you take the last sent message. I did not implement any storage funtionality in this example. You could now use your own logic to implement flat file saving (via ItemSaveMessage() from Token API) or some kind of database storage. I will make a more complete tutorial on that some time later.

I forgot to mention something: When you use objects from the GroupwareTypeLibrary namespace, the built solution will contain another dll: Interop.GroupwareTypeLibrary.dll. You need to cache this dll too in order to make everything work.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.