Signature in Office 365 using Transport Rule Using C# with Power shell commands RRS feed

  • Question

  • I am creating Transport Rule for Signature in Office 365 in my site. I am using Power shell command with c#.  For new emails it is working as expected. But whenever I got  reply or forward the email the signature was appended at last of each email. How to restrict signature for those reply and forward emails. Here is the sample code.

     var pipe1 = psRunSpace.CreatePipeline();
                                   Command NewAddressList1 = new Command("New-TransportRule");
                                   NewAddressList1.Parameters.Add((new CommandParameter("name", "MyRule")));
                                    NewAddressList1.Parameters.Add((new CommandParameter("Enabled ", true)));
                                   NewAddressList1.Parameters.Add((new CommandParameter("ApplyHtmlDisclaimerLocation", "Append")));
                                  NewAddressList.Parameters.Add((new CommandParameter("Priority",0)));
              NewAddressList1.Parameters.Add((new CommandParameter("ApplyHtmlDisclaimerText", "Hear i using Html String")));
                                   Collection<PSObject> NewAddressListResult1 = pipe1.Invoke();

    Monday, June 6, 2016 5:32 AM