Table of Contents

Currencies

The Currencies node allows you to create and manage currencies on a solution, enabling customers to browse and pay in their local currency. Each currency is defined relative to the default (base) currency using an exchange rate, and can also control how prices are formatted (symbol placement, separators, patterns, etc.).

Currencies_01

To create a new currency:

  1. Click New currency
  2. Under Regional info select a culture/region (optional, but recommended)
  3. Set a Rate (an exchange rate )
  4. Optionally mark the currency as Default
  5. Review and adjust the currency settings as needed

Most fields are pre-filled when a culture is selected, but they can be overridden.

Currency properties

Currency properties are divided into two sections: Currency and Settings

Currency

These Currency-fields define the identity and exchange behavior of the currency.

Field Description
Name Display name of the currency (e.g. Danish Krone, US Dollar)
Regional info A .NET culture (e.g. da-DK, en-US). If set, formatting defaults are derived from it
Rate Exchange rate relative to the default currency (see Rate/Exchange Rate)
Default Marks this currency as the base currency

When Regional info is selected, DynamicWeb automatically initializes:

  • Currency name
  • Currency symbol
  • ISO currency code
  • Positive and negative formatting patterns

Settings

The Settings-fields control how prices are formatted.

Field Description
Code ISO currency code (e.g. DKK, USD, EUR)
Symbol Currency symbol (e.g. kr., $, )
Use currency code for format Uses the currency code instead of the symbol when formatting
Positive pattern Controls how positive prices are rendered
Negative pattern Controls how negative prices are rendered

If a culture is selected, Code and Symbol are read-only by default to prevent inconsistencies.

If Use currency code for format is enabled, the currency code replaces the symbol in output, for example:

Currency Output
DKK 1.234,00 DKK
USD USD 1,234.00
RON 1,234.00 RON

This is especially useful for B2B solutions, invoices and exports, and for avoiding ambiguous symbols.

Rate/Exchange Rate

Exchange rates are always defined relative to the default currency and its base rate.

Example:

  • Default currency: DKK
  • Base rate: 10000 (allows 2 decimal precision)

Each additional currency defines how many units of the default currency are required to buy the base rate in the target currency.

Examples:

Currency Rate meaning
USD 74770 → 10000 USD costs 747.70 DKK
TRY 4018 → 10000 TRY costs 40.18 DKK
EUR 74425 → 10000 EUR costs 744.25 DKK

Currency formatting

Currency formatting in DynamicWeb is based on .NET number formatting, with controlled overrides from the currency settings.

At runtime, formatting follows this order:

  1. Culture info (if provided) determines:

    • Decimal separator
    • Thousand separator
    • Default symbol placement
    • Default positive/negative patterns
  2. Currency overrides

    • Positive pattern
    • Negative pattern
    • Symbol vs. code
    • Rounding settings

If no culture is defined on the currency, formatting falls back to the website is running (CurrentCulture).

Positive and negative patterns

The positive pattern and negative pattern settings allow you to specify how you want positive and negative amounts to be rendered.

You can use the dropdowns to select an appropriate pattern, but if you're extending or doing custom development the patterns follow standard .NET meanings:

PositivePattern examples:

Value Example Meaning
0 kr.1.234,00 Symbol before number
1 1.234,00kr. Symbol after number
2 kr. 1.234,00 Symbol before, space
3 1.234,00 kr. Symbol after, space

NegativePattern examples:

Value Example Meaning
0 (kr.1.234,00) Parentheses
1 -kr.1.234,00 Minus before symbol
2 kr.-1.234,00 Minus before number
5 -1.234,00kr. Minus before number, symbol after
14 (kr. 1.234,00) Parentheses with space

Example configurations

Here are some concrete examples of how you can configure currencies on a solution.

The simplest and safest setup is to assign a Regional info to the currency

  • Danish Kroner (DKK)
    • Regional info: da-DK
    • Symbol: kr.
    • Positive result: 1.234,00 kr.
    • Negative result: -1.234,00 kr.
  • US Dollars (USD)
    • Culture info: en-US
    • Symbol: $
    • Positive result: $1,234.00
    • Negative result: -$1,234.00

In this mode:

  • Thousand and decimal separators follow the culture
  • Symbol placement is predictable
  • Formatting behaves consistently across the system

Overriding culture-based formatting (advanced)

You can omit the Culture info and fully control formatting manually. This is useful for currencies that:

  • Do not map cleanly to a specific culture
  • Are used in a multi-lingual or multi-regional context
  • Require custom formatting rules

For example - for Romanian Leu (RON/lei):

  • Culture info: (empty)
  • Code: RON
  • Symbol: lei
  • Use currency code for format: false
  • Positive pattern: 3 (n $)

Result (assuming website culture is en-US):

  • 1,234.00 lei
  • -1,234.00 lei

Important behavior in this setup:

  • Number formatting (, and .) comes from the website culture
  • Symbol placement comes from the currency patterns
  • No automatic localization is applied

This gives full control, but also places responsibility on the implementer to ensure consistency.

To top