8.4Trading requests blocked by user settings/preferences

The MyTrader platform lets the user set options such as "don't allow trades and orders without a stop-loss" or "don't allow trades or orders which risk more than x% of equity" (based on the order's volume and stop-loss).

The following error codes represent breaches of the user's rules:

FXB.ErrorCodes.

Description

TR_TRADINGGLOBALLYDISABLED

User has disabled all trading in the platform's settings

TR_SETTINGSREQUIRESL

User's settings require that all orders and trades have a stop-loss

TR_SLTOOWIDEFORMAXRISK

Volume and stop-loss imply a cash risk which is beyond the user's specified maximum

TR_MINRISKTOOLARGE

Special case of the above: even the minimum trading volume on the market would, with the specified stop-loss, imply a cash risk which is beyond the user's specified maximum

TR_WIDGETTYPECANTTRADE

Your widget (category) has not been given permission to place trades