9 Replies Latest reply: Aug 31, 2012 5:03 PM by Richard Lowe RSS

    Use Variable Value(s) in an Expression

      I hope this is an easy question, I have 1 variable, vCity that someone can select from a predefined list of cities that I need to use for comparing to elements in the app and summing up values.  Here is an example of what I need to do:



      An end user selects whatever city they are interested in on the front end.  For example.

      vCity could = Miami, NY, London, NULL, all values or 1 or more values, etc.


      Then say I have multiple cities data types loaded in the app, such as the cities of the sales person (SalesCity) and the cities of the client (ClientCity), etc.


      Depending on the context, I am using an IF statement to sum up values using the appropriate city type.  So in my expressions I just need to set the value of SalesCity:=vCity or ClientCity:=vCity depending on which one I need to use.   Just as if the person had choosen SaleCity or ClientCity directly.


      Is there an easy way to do this?


      Thanks very much.