What’s New in cTrader Desktop 4.8
What’s New in cTrader Desktop 4.8
13 Jul 2023, 10:15
cTrader Desktop 4.8 Unveils Overlay Indicators, Integrated IDEs for Algo Developers, and Backtesting and Market Replay Reports
The cTrader Desktop 4.8 release delivers overlay indicators, backtesting and market replay reports, integrated IDEs, the ability to run cBots in an external process, and other powerful features.
From now on, you can choose where to display indicators in a chart window: on the chart itself, under the chart in a panel with other indicators, or under the chart in a new panel. You have the freedom to combine several indicators as you like. We have worked tirelessly to make algo trading in cTrader more stable and secure. Now, you can run cBots in an external process. They will not slow down your PC or consume a lot of RAM.
Choose Where to Show Indicators
From now on, you can choose where to show indicators in a chart window:
- On the chart itself
- Under the chart in one panel with other indicators
- Under the chart in a new panel
Combine several indicators as you like.
Edit Algorithms in External IDEs
cTrader Automate is now fully integrated with external development environments: Visual Studio, Visual Studio Code, Rider and Sublime Text. Choose your preferred programme from the drop-down menu and start to code a trading algorithm instantly. All configurations are already set and your IDE is ready for work.
Export Backtesting and Market Replay Reports
You requested it, so we did it! Now you can export, open and share the backtesting or Market Replay reports with other traders. Report is a web document so you can open it on a PC as well as on a smartphone.
Run cBots Separately from the cTrader App
To save your PC’s RAM, you can run cBots in an external process separately from the cTrader Desktop app. Right-click on a cBot and choose “Start in external process”. Now you can close the cTrader app and your cBot will continue to run.
Also, you can run a cBot in an external process using CLI without launching cTrader Desktop at all. Find out more in our Help Center.
cBots Auto Restart
We have developed one more thing to increase algorithmic trading stability. If a cBot process crashes, it will be automatically restarted by cTrader.
Save Parameters of Indicators
Do you use indicators with many parameters? Now you can export and import parameters of your indicators from a file and also share it with other traders.
‘Sleep()’ Method in Automate API
Our invented functionality can switch a cBot to sleep mode for a certain period of time or until a specific time. The most important thing is that compared to `System.Threading.Thread.Sleep()` the new method fully supports backtesting. Find out more in our Help Center.
Specific Folder for Every Algorithm
Algorithms now have specific folders for working with files. When running cBots and custom indicators, data can be securely saved and used as needed without full access to the user’s PC. Find out more in our Help Center.
Controls on Charts in Automate API
Previously chart controls created by trading algorithms were attached to the chart window frame. Now cBots and indicators can attach chart controls to the chart by time, price or time and price. If the chart is moving, the chart controls move with it.
New Properties ‘CurrentPrice’ and ‘Distance’
We have implemented new properties to Automate API:
- Property `CurrentPrice` to the `Position` object
- Properties `CurentPrice` and ‘Distance’ to the object ‘Pending Order’
New property ‘Symbol’
A new ‘Symbol’ property appeared in Automate API. We added it to the following objects: `Position`, `PendingOrder`, `HistoricalTrade`.
New event `BarClosed`
We added a new `BarClosed` event to Automate API. When coding a cBot, you can choose a triggering event: the closing of one bar or the opening of another. Find out more in our Help Center.
Swaps Calculation in Backtesting
Now we calculate swaps in cBot backtesting according to your broker’s settings. That’s why backtesting results have become even more accurate.
tomas.malukas.work
14 Jul 2023, 17:48 ( Updated at: 21 Dec 2023, 09:23 )
cAlgo.API.Line controls are not being updated after coordinate change
Hi Team,
After 4.8.15 update all cAlgo.API.Line controls are not being updated after coordinate change while other are as expected..
Here is example-test where this is clearly visible, please fix the issue.
Thanks.
using cAlgo.API;
namespace cAlgo.Robots
{
[Robot(AccessRights = AccessRights.FullAccess)]
public class TESTS : Robot
{
protected override void OnStart()
{
#if DEBUG
Debugger.Launch();
#endif
line.X2 = Chart.Width;
Chart.AddControl(canvasMain);
canvasMain.AddChild(btn);
canvasMain.AddChild(tbtn);
canvasMain.AddChild(line);
canvasMain.AddChild(cb);
canvasMain.AddChild(tb);
canvasMain.AddChild(border);
border.Child = stack;
stack.AddChild(stackBtn);
}
protected override void OnTick()
{
btn.Top += 10; //Correct, button is moving
tbtn.Top += 10; //Correct, tbutton is moving
border.Top += 10; //Correct, border is moving
cb.Top += 10; //Correct, checkbox is moving
tb.Top += 10; //Correct, textbox is moving
line.Y1 += 10; //WRONG, not moving
line.Y2 = line.Y1; //WRONG, not moving
}
Canvas canvasMain = new();
Button btn = new()
{
Top = 0,
Left = 0,
Text = "btn"
};
ToggleButton tbtn = new()
{
Top = 0,
Left = 50,
Text = "tbtn"
};
Border border = new()
{
Top = 0,
Left = 100,
BorderColor = Color.Red,
BorderThickness = 2
};
StackPanel stack = new()
{
Orientation = Orientation.Vertical
};
Button stackBtn = new()
{
Top = 0,
Text = "btnStack"
};
CheckBox cb = new()
{
Top = 0,
Left = 200,
Text = "cb"
};
TextBox tb = new()
{
Top = 0,
Left = 250,
Text = "tb"
};
Line line = new()
{
X1 = 0,
Y1 = 200,
X2 = 1000,
Y2 = 200,
StrokeThickness = 10,
StrokeColor = Color.Red,
};
}
}
@tomas.malukas.work