Addin dll

Dear Colleagues,I have the following problem. I ported a customized R5 lotus mail template to notes R6.5. To this template is attached a custom dll library which uses the EMRegister function (notes api) with the EM_NSFNOTEOPENEXTENDED parameter in R6. The original parameter in R5

was EM_NSFNOTEOPEN, but this was discontinued. Lotus notes calls this callback when a NSF note document is opened, at least this was the issue in R5. In R6 NSFNOTEOPENEXTENDED is called much more times than in R5, I couldn’t realize exactly when.

There is a situation, I copy a mail document in the inbox folder (I press Ctrl+C), than I would like to know somehow in my EM callback routine, that a copy operation is issued to trigger some functionality.

I tried several parameters of EMRegister like EM_NSFNOTECOPY, EM_NSFDBCOPYNOTE etc. but none of it work. My question is, is there any way to know through the EM callbacks that the Ctrl+C was issued on a notes mail in a folder?

Or should I use another notification insted of EM_NSFNOTEOPENEXTENDED? I also tried EM_NSFNOTEOPEN, but it did not work at all.

Any help would be much appreciated.

Subject: addin dll

i don’t get it. why do you think EM_NSFNOTEOPEN is discontinued in r6? it’s still there in r7. and EM_NSFNOTEOPENEXTENDED does also exist in r5.

what exactly do you want to do?

what about EM_NSFADDTOFOLDER?

if notes are copied a db is being created called ~clipbrd.ncf and the docs are copied here. maybe that helps.

Markus Seitz

markus.seitz@icodex.com

Subject: RE: addin dll

Hello Markus,Thanks for you answer.

I am sorry, I miswrote it: EM_NIFOPENNOTE is discontinued. And now I am trying with EM_NSFNOTEOPEN and …EXTENDED.

I do not know the exact difference between them, but using the first one, my function is not called. And with the EXTENDED one, my function is called every time when someone touch a mail (eg. set its property, copy, etc.).

Actually, this function decrypts the mail, and I want to do it at mail opening only. But this function is triggered when user press ctrl+c and ctrl+v on a mail. In this case I want to detect it and quit from the decrypt function.

Subject: RE: addin dll

so you like to get your exthandler triggered only if a user opens it manually in client (or in preview pane).

you use your own encryption? if so i know a consultant that once helped out a company that did a similar thing. i’m not sure if they’ve found a solution, but feel free to mail me so i can make a contact.

thats really a hard thing to do i think - so just some thoughts:

first i would try to log all flags from EM_NSFNOTEOPENEXTENDED, maybe you can find one that’s only set when its opened for ui. (maybe expand flag?)

does decryption need user-interaction (providing pwd)?

are you able to modify db-design? you could then set a flag in notes-ini in one of view-actions and check if exthandler is called right after that action. maybe Queryopendocument is called before EM_NSFNOTEOPENEXTENDED. (timedependent, no good idea at all)

Markus Seitz

markus.seitz@icodex.com

Subject: RE: addin dll

Yes, it is an own encryption and it needs user interaction.

Unfortunately NSFNOTEOPENEXTENDED causes much more callback than NIFOPENNOTE did, so I have to handle somehow all the wanted and unwanted calls.

Now all the regarding things are solved, I have had problems with copy-paste only (at least for the moment:)), but I succeeded in solving it yesterday evening by your idea (~clipbrd.ncf). So thank you so much, you really made me happy. :slight_smile:

Best regards,

DD

Subject: RE: addin dll

how did you succeed to check if docs are copied to clipboard rather then opened for displaying in ui?

Markus Seitz

markus.seitz@icodex.com

Subject: RE: addin dll

The note is in the clipboard and its write access time is less then 2 seconds old. :)Do you have better idea?

Subject: was assuming something like this:)

currently i think i can’t offer a better idea.

i’m just afraid that - since notes client has millions of features - there might be other things you’re missing. like preview or actions “reply to” (from view)…

but i think once the occure you’ll be able to find a fix.

Markus Seitz

markus.seitz@icodex.com