Currency Converter

LANSA

Currency Converter
Example 105 - Rating: common
The Things that Make Up this ExampleTo Execute this Example

This currency converter can be used to display an amount in a particular currency and then, by choosing a different currency from the drop down list or the list view, the currency is converted. The example uses a simple table to work out the exchange rates (buying and selling) between two currencies. In reality the component that does the work will need to be modified to represent a more real world scenario where determining the latest exchange rate to use is a more difficult task.

There are two reusable components in this example that both perform the same task. The only difference between the two is visually. One component using a drop down list with the three letter currency code and the other component using a list view with an icon of a flag and the three letter currency code. The internals of the components are exactly the same.

For this example you will need to create the fields and the files in the repository and the example will create sample data.

Currencies can be converted directly (e.g. AUD to USD) or via a currency (e.g. AUD to FFR via USD = AUD to USD to FFR)

Keywords
CurrencyConvert
ConversionEuro
Example 105