/ Forums / Advansys Formativ / Creating Solutions with Formativ / Integrating Applets with Rule-based Replies

  • Creator
    Topic
  • #4289
    ihertanto
    Participant

      I would like to execute an applet when a user creates a rule-based message such as an Out-of-Office reply. The applet is supposed to insert text into the body of the message before it is saved in the rule. What “event” do I integrate the applet with to achieve this?

      Much appreciated.

    • Author
      Replies
    • #7739
      ihertanto
      Participant

        To add to my post (above)…

        Here is the problem (maybe someone on your team can help me come up with a solution):

        All outgoing messages must have a classification header in the message body. We have an applet that launches on the Send event and prompts the user to select a classification.

        When the user creates a holiday rule, the auto-sent message does not contain a classification.

        We need to find a way to make sure that all auto-replies have this classification in the body of the message. Whether this text is inserted during the rule creation, or whether it is inserted on the auto-send event of the message, we need to know how this can be done.

        Any suggestions?

        #7737
        Support 2
        Moderator

          You can’t use events to do what you need because rules are executed and the responses created at the post office level.

          There may be a couple of possibilities. If the standard GroupWise classifications (not custom ones) are suitable for your needs, then you can set the default GroupWise classification (using the Client or an applet) for the account which has the vacation rule enabled. Every rule generated reply would then include the selected GroupWise classification within its body text.

          The other option is to create a custom ‘out of the office rule’ applet which inserts classification text within the reply action.

          Regards,

          Advansys Support

          #7740
          ihertanto
          Participant

            Thanks for your reply.

            We would need to use custom classifications (not the standard GroupWise ones) for our outgoing messages.

            I have downloaded the Out of Office Rule Applet trial, and would like to see how you are launching the Rule List configuration window from within the applet. If I can create my own version of this applet, I intend to interact with the rule creator and insert the classification into the rule message body before the rule is saved.

            Can you show me how the Out of Office Rule applet grabs onto the Rule configuration module?

            I appreciate your help.

            #7741
            ihertanto
            Participant

              Another approach… if we were to enable the standard GroupWise classifications, would it be possible to change the GroupWise classification strings or add to the list?

              Thanks in advance.

              #7736
              Support 2
              Moderator

                quote:


                Another approach… if we were to enable the standard GroupWise classifications, would it be possible to change the GroupWise classification strings or add to the list?


                Unfortunately custom classifications only work at the client end. Rules are executed at by the Post Office Agent and it doesn’t support client side custom classifications, only the GroupWise standard classifications.

                Regards,

                Advansys Support

                #7738
                ihertanto
                Participant

                  Thanks for the reply. I would really like to understand how your Out of Office Applet is interfacing with the Rules List. The commercial solution that I downloaded is encrypted. Would you please send me an example on how you’re grabbing the rules list and opening it from within the applet?

                  What happens to the rule during run-time (at the PO level) is out of my hands, I understand that. I hope to interact with the rules on the client end only.

                  #7744
                  ihertanto
                  Participant

                    Sorry I spoke too soon. I found the GroupWise.RuleLstDlg() command for opening the GW Rules Config module in the Formativ Language Guide. I also see how your Out of Office Applet is immitating the GW Rules.

                    However—and this might be too ambitious—but can we accomplish the following:

                    When a user composes a GroupWise message, it can be accessed using the GroupWise.ComposingItem property (CurrentItem). The body of this message can be accessed using GroupWise.ComposingItem.BodyText propety.

                    Now, when a user composes a GroupWise rule, is there not a similar property that returns the rule currently being composed and then a second property that allows you to write to the BodyText of the rule’s Reply action?

                    If not, please confirm that there is absolutely no way to customize GroupWise rules (on the client side, BEFORE rules are saved and executed at run-time) without rewriting the entire rule module in a custom applet.

                    I appreciate your input.

                    #7743
                    Support 3
                    Participant

                      quote:


                      Now, when a user composes a GroupWise rule, is there not a similar property that returns the rule currently being composed and then a second property that allows you to write to the BodyText of the rule’s Reply action?


                      Unfortunately, there is no Token APIs available to return current composed rule. If you want to edit the rule’s action then you need to rewrite the rule. You may need to use the RuleAddActionReplyWithText token to set the reply text. See the Formativ Language Guide and GroupWise Token API for more information.

                      Please note, you can use ThrowToken method which uses the native GroupWise Token Commander to execute a given token. See the forum post below about the ThrowToken method:
                      http://www.advansyscorp.com/forums/topic/3121058911/

                      Regards,
                      Advansys Support

                      #7742
                      ihertanto
                      Participant

                        Thank you very much. Your reply was thorough and extremely helpful! I will see what I can do with the options that are available to me.

                        Regards,

                        IH

                        #7735
                        Support 3
                        Participant

                          Thanks for your feedback.

                          Regards,
                          Advansys Support

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