Spotware announces cTrader Automate API 4.0
Fintech company Spotware Systems has announced cTrader Automate API 4.0 which is included in cTrader Desktop 4.0. cTrader Automate API 4.0 comes with a raft of new features.
To improve keyboard interaction in cTrader Desktop 4.0, all chart views now always contain one chart that is marked as active. Such a chart will handle all chart related hotkeys such as Space to open search, or Up and Down arrow keys to change charts period.
With this improvement cBots and indicators now can handle keyboard events with a few restrictions:
- Keyboard events will be raised only for cBots and indicators from the active chart
- If key or keystroke was handled by cTrader as a hotkey, it will not be passed to cBots and indicators
Chart.KeyDown event will be raised for every keyboard event when a single key or a keystroke with modifier keys (Ctrl, Alt, and Shift) was pressed. Events that are handled as hotkeys by cTrader will not be raised for cBots and indicators.
- Chart.AddHotkey method
The second way to handle keyboard events is a simplified solution to assign a custom hotkey for some action. Using Chart.AddHotkey method you can set a hotkey for an action using Key enumeration or using a string like “Ctrl + R”. This method will return false if such hotkey is already in use in cTrader, or if another cBot or indicator already uses the same custom hotkey.
- Selected drawings
In the previous version, only a single drawing could be selected. cTrader 4.0 allows selecting multiple drawings. All drawings can be selected using Ctrl + A hotkey. And drawing can be added/removed to/from the selection using the mouse click with the Ctrl key pressed.
With this change, old ObjectSelectionChanged event was deprecated and new ObjectsSelectionChanged event was added. Old event argument had a single ChartObject property. New event contains two collections ObjectsAddedToSelection and ObjectsRemovedFromSelection . Also, now you can use the SelectedObjects property to get the list of all selected drawings in the main chart area or indicator area.
- Drawings added/updated/removed events
ObjectAdded , ObjectUpdated , and ObjectsRemoved events were deprecated. Old events contained an arguments with a single ChartObject property.
New events ObjectsAdded , ObjectsUpdated , and ObjectsRemoved were added, each contains a collection of drawings.
This change allows handling a single event when a user pastes multiple drawings from the clipboard (ObjectsAdded event) or drags multiple drawings (ObjectsUpdated event).
All old events are working as before. When an event occurs with multiple drawings, an old event will be raised for each drawing, only if a subscription for such an event exists.
Whenever the new version is considered stable and ready for release to production environments.
cTrader Automate functionality allows automating the trading process by using the cBots and improving trading by using the Indicators. The cBots are custom configurable strategies that can execute trades independently without human control or monitoring. The Indicators are used to help in manual trading, as well as to be integrated into cBots to indicate the trends and providing signals for potential changes in trends.
One can build cBots and Indicators using the Automate code editor, backtest them for verification and finally use them.
The key advantage of using the cBots is that they facilitate entering trades more accurately as they can send orders faster than a human. Traders simply need to start a cBot and then stop it manually or programmatically.