SetCurrencyPreference command

Set the currency preference for the user running this command. For a generic user--one for whom there is no information stored--the preference will apply for the duration of the session only. For all other users the currency preference will be saved with the user's profile.

Command structure

http://host_name/path/
The fully qualified name of your WebSphere Commerce Server and the configuration path

Diagram of the command structure: the command starts with the fully qualified name of your WebSphere Commerce Server and the configuration path, followed by the command name, SetCurrencyPreference  and the ? character. End the command with a list of parameters in the form of name value pairs. Separate each name value pair with the & character. For a detailed description of the parameters and their values, refer to the list entitled Parameter values.

Parameter values

forUser
The logon ID of the user on whose behalf the command will be run; only a person with a security role of Customer Service Representative (or those roles that include the CSR tasks) can specify this parameter
forUserId
Same as forUser, but identifying the user by the internal user ID, as found in the USERS table
langId
Sets or resets the preferred language for the duration of the session; the supported languages for a store are found in the STORELANG table
URL (Required)
The URL to be called when the command completes successfully
currency (Required)
The three-letter ISO code for the currency that will become the preferred currency for this customer.

Example

This example changes a customer's preferred currency to Canadian dollars (CAD). If the command is successful, FVTestSite.jsp will display.

    http://myhostname/webapp/wcs/stores/servlet/SetCurrencyPreference?currency=CAD
    &URL=FVTestSite.jsp

Behavior

Exception Conditions

If no price could be found for any of the products or items in a pending order, the command throws the ECApplicationException exception specifying the RetrievePriceError error view command.