This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

VBScript - Arithmetic Operation

Former Member
Former Member
Hi All,
I am trying to do a claims return process in M-Files.
I want the expenditures, transportation cost and Hotel cost be added and then subtracted from the total budget.
The output should be automatically present in the Claims/Return Property definition.

Note: All datatypes are number.

Below is what I have tried doing


Option Explicit

Dim TotalBudget
Dim HotelCost
Dim Expenditure
Dim TransporationCost

TotalBudget = PropertyValues.SearchForProperty(1050).TypedValue.DisplayValue
HotelCost = PropertyValues.SearchForProperty(1052).TypedValue.DisplayValue
Expenditure = PropertyValues.SearchForProperty(1057).TypedValue.DisplayValue


Output = HotelCost + Expenditure + TransportationCost - TotalBudget