Source: https://vaultcrmhelp.veeva.com/doc/Content/CRM_topics/Events/EventBusinessRules/ExpenseEstRules.htm

## Creating Expense Estimate Creation Rules

Estimating event expenses during the planning phase is essential for keeping costs within the allocated budget. Event admins can create Expense Estimate Creation rules that automate creating expense estimate records, streamlining the planning process and reducing user errors when estimating expenses.

Several types of Expense Estimate Creation rules exist, each of which can be controlled by country and event type:

* Meal Estimates
* Speaker Travel Estimates
* Speaker Lodging Estimates
* AV Equipment Estimates
* Flat Fee Estimates

See [Examples of Expense Estimate Creation Rules](ExpenseEstRulesExample.htm) for more detailed examples of these rules.

**Who can use this feature?**

* Business Admin Users - Browser
* [Creating Expense Estimate Creation Rules](#Creating)
* End Users - Browser, iPad
* [Using Expense Estimate Creation Rules](#Using)
* Users require an Events Management License

### Configuring Expense Estimate Creation Rules for

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Business Admin Users](#)

To configure this feature:

1. Ensure the following features are configured:

   * [Configuring Events Management](../Configuration/Config.htm)
   * [Event Business Rules Overview](EventBusinessRules.htm)
2. Grant the following permissions:

   | Object | Object Permission | Object Types | Fields | Field Permission |
   | --- | --- | --- | --- | --- |
   | em\_business\_rule\_\_v | CRED | * expense\_estimate\_meal\_rule\_\_v * expense\_estimate\_speaker\_travel\_rule\_\_v * expense\_estimate\_speaker\_lodging\_rule\_\_v * expense\_estimate\_av\_equipment\_rule\_\_v * expense\_estimate\_Flat\_Fee\_rule\_\_v | * expense\_type\_\_v * minimum\_travel\_distance\_\_v * maximum\_travel\_distance\_\_v * distance\_unit\_type\_\_v * rate\_type\_\_v * av\_equipment\_\_v * flat\_fee\_expense\_\_v * meal\_type\_\_v * speaker\_transportation\_method\_\_v * speaker\_lodging\_type\_\_v | Edit |
   | em\_business\_rule\_configuration\_\_v | CRED | em\_business\_rule\_configuration\_\_v | * cost\_\_v * local\_currency\_\_sys | Edit |
   | em\_event\_\_v | CRED | All appropriate object types | * av\_equipment\_\_v * flat\_fee\_expense\_\_v * meal\_type\_\_v | Edit |
   | em\_event\_speaker\_\_v | CRED | All | * speaker\_transportation\_method\_\_v * speaker\_travel\_distance\_\_v * speaker\_lodging\_type\_\_v * speaker\_lodging\_nights\_\_v * distance\_unit\_type\_\_v | Edit |
   | em\_expense\_estimate\_\_v | CRED | All appropriate object types | * event\_business\_rule\_\_v * event\_business\_rule\_parameter\_\_v | Edit |

#### Configuring Event Format and Location Type in Event Business Rules

To only apply a business rule to certain event formats or location types, improving both efficiency and compliance when planning events:

1. Grant Edit permission to the following **em\_business\_rule\_configuration\_\_v** fields:

   * event\_format\_\_v
   * location\_type\_\_v
2. Navigate to **Admin > Configuration > Objects > em\_business\_rule\_configuration\_\_v > Layouts**.
3. Add the following fields to the appropriate em\_business\_rule\_configuration\_\_v layouts:

   * event\_format\_\_v
   * location\_type\_\_v

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)End Users](#)

To configure this feature:

1. Ensure the following features are configured:

   * [Configuring Events Management](../Configuration/Config.htm)
   * [Event Business Rules Overview](EventBusinessRules.htm)
2. Grant the following permissions:

   | Object | Object Permission | Object Types | Fields | Field Permission |
   | --- | --- | --- | --- | --- |
   | em\_business\_rule\_\_v | R | * expense\_estimate\_meal\_rule\_\_v * expense\_estimate\_speaker\_travel\_rule\_\_v * expense\_estimate\_speaker\_lodging\_rule\_\_v * expense\_estimate\_av\_equipment\_rule\_\_v * expense\_estimate\_flat\_fee\_rule\_\_v | * expense\_type\_\_v * minimum\_travel\_distance\_\_v * maximum\_travel\_distance\_\_v * distance\_unit\_type\_\_v * rate\_type\_\_v * av\_equipment\_\_v * flat\_fee\_expense\_\_v * meal\_type\_\_v * speaker\_transportation\_method\_\_v * speaker\_lodging\_type\_\_v | Read |
   | em\_business\_rule\_configuration\_\_v | R | All | * cost\_\_v * local\_currency\_\_sys | Read |
   | em\_event\_\_v | RE | All appropriate object types | * av\_equipment\_\_v * flat\_fee\_expense\_\_v * meal\_type\_\_v | Edit |
   | em\_event\_speaker\_\_v | RE | All | * speaker\_transportation\_method\_\_v * speaker\_travel\_distance\_\_v * speaker\_lodging\_type\_\_v * speaker\_lodging\_nights\_\_v * distance\_unit\_type\_\_v | Edit |
   | em\_expense\_estimate\_\_v | RE | All appropriate object types | * event\_business\_rule\_\_v * event\_business\_rule\_parameter\_\_v | Edit |
3. Place all configured **em\_event\_\_v** and **em\_event\_speaker\_\_v** fields on the appropriate layouts.

#### Configuring Event Format and Location Type in Event Business Rules

To only apply a business rule to certain event formats or location types, improving both efficiency and compliance when planning events, grant Read permission to the following em\_business\_rule\_configuration\_\_v fields:

* event\_format\_\_v
* location\_type\_\_v

### Creating Expense Estimate Creation Rules as

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Business Admin Users](#)

All Event Rules are created from the Event Business Rules tab. The selected object type of the em\_business\_rule\_\_v object determines which fields admins must populate:

1. Navigate to the **Event Business Rules** tab.
2. Create a new Event Rule with the appropriate object type:

   * expense\_estimate\_meal\_rule\_\_v
   * expense\_estimate\_speaker\_travel\_rule\_\_v
   * expense\_estimate\_speaker\_lodging\_rule\_\_v
   * expense\_estimate\_av\_equipment\_rule\_\_v
   * expense\_estimate\_flat\_fee\_rule\_\_v
3. Select **Next**.
4. Populate the following fields:

   * name\_\_v
   * expense\_type\_\_v – Select the appropriate em\_expense\_type\_\_v record

     Expense Estimates are not created if the selected Expense Type is not active or is a child of another em\_expense\_type\_\_v record.
   * run\_rule\_event\_action\_\_v – Enter the appropriate button name to run the rule whenever the event organizer selects the button. Enter only one button name and do not use any of the following buttons:
   * cancel\_event\_\_v
   * reschedule\_\_v
5. Populate the following additional fields based on the selected object type:

   | Object Type | Additional Fields | Description |
   | --- | --- | --- |
   | expense\_estimate\_meal\_rule\_\_v | meal\_type\_\_v | The picklist value added to an applicable event’s meal\_type\_\_v multi-select picklist.  This field cannot be edited after the record is created. |
   | expense\_estimate\_speaker\_travel\_rule\_\_v | speaker\_transportation\_method\_\_v | The picklist value added to an applicable Event Speaker’s speaker\_transportation\_method\_\_v picklist.  This field cannot be edited after the record is created. |
   | minimum\_travel\_distance\_\_v | The minimum speaker travel distance required to qualify for this rule. |
   | maximum\_travel\_distance\_\_v | The maximum speaker travel distance required to qualify for this rule. |
   | distance\_unit\_type\_\_v | Select either Kilometers or Miles. |
   | expense\_estimate\_speaker\_lodging\_rule\_\_v | rate\_type\_\_v | Determines how the estimated cost is calculated. Select one of the following values:  * Day * Event See [Using Expense Estimate Creation Rules](#Using) for more information. |
   | speaker\_lodging\_type\_\_v | The picklist value added to an applicable Event Speaker’s speaker\_lodging\_type\_\_v picklist.  This field cannot be edited after the record is created. |
   | expense\_estimate\_av\_equipment\_rule\_\_v | av\_equipment\_\_v | The picklist value added to an applicable event’s av\_equipment\_\_v multi-select picklist.  This field cannot be edited after the record is created. |
   | rate\_type\_\_v | Determines how the estimated cost is calculated. Select one of the following values:  * Hour * Day * Event See [Using Expense Estimate Creation Rules](#Using) for more information. |
   | expense\_estimate\_flat\_fee\_rule\_\_v | flat\_fee\_expense\_\_v | The picklist value added to an applicable event’s flat\_fee\_expense\_\_v multi-select picklist.  This field cannot be edited after the record is created. |
   | rate\_type\_\_v | Determines how the estimated cost is calculated. Select one of the following values:  * Hour * Day * Event See [Using Expense Estimate Creation Rules](#Using) for more information. |
6. Select **Save**.

#### Creating Event Rules Configurations

After the event rule is created, admins must associate the event rule with a new em\_business\_rule\_configuration\_\_v record to determine which event type, country, and timespan the rule should apply to.

To associate event rules to em\_business\_rule\_configuration\_\_v records, navigate to the Event Business Rule Configurations section of the appropriate rule.

![](../../../Resources/Images/Events/BusRules/EMBusRuleConfigCreate.png)

Select Create, then populate the following fields:

* event\_business\_rule\_\_v – Automatically populates with the appropriate event rule
* event\_type\_\_v – Enter the appropriate em\_event\_\_v object type the event rule applies to
* country\_\_v – Use the lookup to select the appropriate country\_\_v record
* rule\_start\_date\_\_v
* rule\_end\_date\_\_v
* cost\_\_v – The cost of each instance of the associated Expense Estimate rule. Used when calculating estimate costs. For example, in an AV Equipment Estimate rule with a Rate Type of Hour, cost\_\_v represents the estimated cost of one hour of equipment use.
* local\_currency\_\_sys – Use the picklist to select the appropriate currency.

Business admins can create different limits for different countries by creating additional em\_business\_rule\_configuration\_\_v records.

Only one business rule configuration can be active for each combination of event\_type\_\_v, event\_business\_rule\_\_v, and country\_\_v. An error occurs when attempting to save a business rule configuration with a matching event\_type\_\_v, event\_business\_rule\_\_v, and country\_\_v of another active record.

#### Specifying a Format or Location for an Event Business Rule

To specify the format or location an Event Business Rule should apply to:

1. Edit the appropriate em\_business\_rule\_configuration\_\_v record associated with the business rule. The following types of business rules are supported:

   * Meal Estimates
2. Populate the following fields:

   * event\_format\_\_v – Only applies the business rule to em\_event\_\_v records with matching event\_format\_\_v fields. Multiple values can be specified using a double semicolon delimited list, for example:

     in\_person\_\_v;;virtual\_\_v
   * location\_type\_\_v – Only applies the business rule to em\_event\_\_v records with matching location\_type\_\_v fields. Multiple values can be specified using a double semicolon delimited list, for example:

     in\_office\_\_v;;out\_of\_office\_\_v

   These fields can be used independently or together for even greater specificity.
3. Select **Save**.

### Using Expense Estimate Creation Rules as

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)End Users](#)

Event organizers can use fields on the em\_event\_\_v and em\_event\_speaker\_\_v layouts in conjunction with event rules to automatically generate expense estimates. These fields display to event organizers as picklists. The displayed values of these picklists depend on the event matching the Country and Event Type of active event rules of the appropriate object type:

* meal\_type\_\_v – Used for expense\_estimate\_meal\_rule\_\_v type event rules
* av\_equipment\_\_v – Used for expense\_estimate\_av\_equipment\_rule\_\_v type event rules
* flat\_fee\_expense\_\_v – Used for expense\_estimate\_flat\_fee\_rule\_\_v type event rules

For expenses relating to speakers, event organizers can populate the following fields on the appropriate em\_event\_speaker\_\_v record:

* speaker\_travel\_distance\_\_v – Used to record a speaker’s traveling distance from an event
* speaker\_transportation\_method\_\_v – A picklist used in expense\_estimate\_speaker\_travel\_rule\_\_v type event rules. The values of this picklist are determined by active event rules where the speaker\_travel\_distance\_\_v field is within the range of the event rule
* speaker\_lodging\_type\_\_v – A picklist used in expense\_estimate\_speaker\_lodging\_rule\_\_v type event rules. The values of this picklist depend on the event type and country matching active event rules.
* speaker\_lodging\_nights\_\_v – Automatically populates based on the number of days of the event

After populating all the appropriate fields, event rules run whenever the event organizer selects the button corresponding to the event rule’s run\_rule\_event\_action\_\_v field.

#### Expense Estimates Created from Rules

Whenever an expense estimate creation rule runs, an em\_expense\_estimate\_\_v record is created with the following values:

* Event – References the corresponding em\_event\_\_v record
* Estimate – Uses the cost\_\_v field from the corresponding em\_business\_rule\_configuration\_\_v record to calculate a total estimate based on each object type:

  | Rule Record Type | Calculation Logic |
  | --- | --- |
  | expense\_estimate\_meal\_rule\_\_v | Also uses the Estimated\_Attendance\_vod field from the corresponding event:  Estimated\_Attendance\_vod \* cost\_\_v  If the event organizer selects multiple meal types, each meal type is independently calculated. |
  | expense\_estimate\_speaker\_travel\_rule\_\_v | cost\_\_v |
  | expense\_estimate\_speaker\_lodging\_rule\_\_v | Also uses the speaker\_lodging\_nights\_\_v field from the appropriate Event Speaker.  When the rate\_type\_\_v of the Event Rule = Day:  cost\_\_v \* speaker\_lodging\_nights\_\_v  When the rate\_type\_\_v of the Event Rule = Event:  cost\_\_v |
  | expense\_estimate\_av\_equipment\_rule\_\_v | When the rate\_type\_\_v of the Event Rule = Hour:  cost\_\_v \* Number of Hours at the Event  When the rate\_type\_\_v of the Event Rule = Day:  cost\_\_v \* Number of Nights at the Event  When the rate\_type\_\_v of the Event Rule = Event  cost\_\_v  If the event organizer selects multiple AV equipment types, each type is independently calculated. |
  | expense\_estimate\_flat\_fee\_rule\_\_v | When the rate\_type\_\_v of the Event Rule = Hour:  cost\_\_v \* Number of Hours at the Event  When the rate\_type\_\_v of the Event Rule = Day:  cost\_\_v \* Number of Nights at the Event  When the rate\_type\_\_v of the Event Rule = Event  cost\_\_v  If the event organizer selects multiple flat fee types, each type is independently calculated. |
* Expense Type – The value of the expense\_type\_\_v field from the Event Rule used to create the record. If multiple expense estimates were created with the same expense type, roll ups calculate based on the first created expense estimate record. This record links to the expense line record.
* EM Business Rule – References the Event Rule used to create the record
* EM Business Rule Parameter – Displays the rule-specific parameter from the Event Business Rule used to create the record
* Event Budget – References the corresponding em\_event\_budget\_\_v record associated with the record’s em\_event\_\_v field

  If there is more than one budget associated with the event, this field defaults to the oldest associated budget based on the CreatedDate field. This field remains blank if there are no associated budgets.

If an Expense Estimate Creation rule is deleted, the corresponding picklist option no longer displays to end users, but any em\_expense\_estimate\_\_v records created by the rule are not deleted.

### Related Topics

[Event Business Rules Overview](EventBusinessRules.htm)

[Examples of Expense Estimate Creation Rules](ExpenseEstRulesExample.htm)

[Warning Text and Tokens](WarningTextTokens.htm)
