/ Forums / Advansys Formativ / Creating Solutions with Formativ / Are messages marked with an account identifier

  • Creator
    Topic
  • #4278
    jcromwijk
    Participant

    Hi,

    I am working on an applet to sort outgoing e-mails (triggers on the onsend event).

    This applet is working on normal accounts and on proxied accounts.

    But when the user is creating an emailmessage in his normal account and he switches to the proxied account and back to the message. Then when the user sends the mailmessage the applet says he is in the proxied account.

    Is there any way to detect in which account the message was created. So that my problem can be fixed.

    Greetings,
    Jan Cromwijk

  • Author
    Replies
  • #7697
    Support 3
    Participant

    quote:


    when the user sends the mailmessage the applet says he is in the proxied account.


    Your applet should check the CurrentAccount Proxied property to determine whether the account is a proxy account. See the code below to check the proxied property.

     
    msgbox Client.clientstate.currentaccount.proxied     
    

    quote:


    Is there any way to detect in which account the message was created.


    If you access the message object using Object API (http://developer.novell.com/documentation/gwobjapi/index.html?gwobjenu/data/h7ikbsqg.html) then you can check the Parent property of the message which will return the Account object.

      
    set oAccount = oMsg.parent
    msgbox oAccount.owner.displayname & vbcrlf & oAccount.owner.emailaddress
    

    If you access the message using Token API (http://developer.novell.com/documentation/gwtoken/index.html?gwtokens/data/hj8ej8g5.html) then you can check the From text.

      
    msgbox GroupWise.ItemGetText("X00", itfFrom)
    

    Hope this helps.

    Regards,
    Advansys Support

    #7695
    jcromwijk
    Participant

    Thanks!

    quote:


    set oAccount = oMsg.parent
    msgbox oAccount.owner.displayname & vbcrlf & oAccount.owner.emailaddress


    Works good!

    #7696
    Support 3
    Participant

    Thanks for the update.

    Regards,
    Advansys Support

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.