Scenario Overview

In this scenario the business requirement is to remove all PDF email attachments that are over 1MB in size. The end user needed to do this manually from a Command Console.

N52 Formula Manager Solution

The Formula Manager solution works like this,

  • We create a formula of type 'Command Console'
  • The formula retrieves the first 10 email attachments to be deleted
  • It then deletes the attachment

N52 Formula Manager Steps

The following set of steps will set this formula up for you,

  • Create a new formula of type 'Command Console'
  • Copy & paste the formula below into the formula description field
  • Click save



The following set of steps will create the formula detail named 'RemoveEmailAttachments' for you,

  • Using the subgrid in the bottom right hand corner create a new formula detail record.
  • Set the name field to 'RemoveEmailAttachments'
  • Set the fetch-xml to the query below
  • Click Save


<fetch version="1.0" output-format="xml-platform" count="10" mapping="logical" distinct="false">
  <entity name="activitymimeattachment">
    <attribute name="activitymimeattachmentid" />
    <attribute name="filename" />
    <attribute name="filesize" />
    <attribute name="mimetype" />
    <filter type="and">
      <condition attribute="mimetype" operator="eq" value="application/pdf" />
      <condition attribute="filesize" operator="gt" value="1024000" />

Now when you want to execute the command just click the lighting bolt on the North52 formula editor ribbon. This will pop-up a dialog box which you can execute the command.

Did you know?

You can easily add powerful business logic to Dynamics Portals

North52 Business Process Activities provides the ability to easily configure and execute business rules on Dynamics Portals Entity Forms.

We make it very easy for you to configure simple or complex logic that changes the behaviour of the form:

  • Show/hide fields
  • Show/hide sections
  • Set fields required/not required
  • Show/hide notifications
  • Set field values
Learn more about North52 BPA for Dynamics Portals