The issue is, as stated in a multitude of other posts, that the cloud is broken, and you should use a VPS or run locally.
Spotware obviously doesn't care, because they've made no mention of it, or that they're investigating, or something else, with all the user reports of issues with the cloud.
Then after the ExecuteMarketOrder statement, find the position and print the SL and TP values to confirm they've been set as expected.
Show us a screen capture showing the before and after values from the logging. Let's see what they say.
Thanks for helping. first thing i notice is the logs not showing pips, only whole points. Does that mean it does n0t know pips? Considering that the log seems to be giving correct answer if it is rounding the price, although i want it to pip accuracy
LOGS
05/02/2025 00:00:00.000 | Info | CBot instance [forum help, XAUUSD, m5] started. 05/02/2025 00:40:00.443 | Trade | Executing Market Order to Buy 1 XAUUSD (SL: 2845, TP: 2847) 05/02/2025 00:40:00.443 | Trade | → Executing Market Order to Buy 1 XAUUSD (SL: 2845, TP: 2847) SUCCEEDED, Position PID1 05/02/2025 00:45:00.438 | Trade | Executing Market Order to Buy 1 XAUUSD (SL: 2847, TP: 2848) 05/02/2025 00:45:00.438 | Trade | → Executing Market Order to Buy 1 XAUUSD (SL: 2847, TP: 2848) SUCCEEDED, Position PID2
TRADES EXECUTED
Serial # Order ID Position ID Event Time (UTC+7) Volume Quantity Type Entry price TP SL Closing price Gross profit Pips Balance Equity
Again with rounding it seems to be logging the correct SL/TP , but on both tests the SL/TP it actually implements is almost the same for both tests on same data…SL and TP are both aprroximately 28pts away. On previous times ive run this ive seen them around 25-26pts away.
05/02/2025 00:00:00.000 | Info | CBot instance [forum help, XAUUSD, m5] started. 05/02/2025 00:40:00.443 | Trade | Executing Market Order to Buy 1 XAUUSD (SL: 2844, TP: 2851) 05/02/2025 00:40:00.443 | Trade | → Executing Market Order to Buy 1 XAUUSD (SL: 2844, TP: 2851) SUCCEEDED, Position PID1 05/02/2025 00:45:00.438 | Trade | Executing Market Order to Buy 1 XAUUSD (SL: 2845, TP: 2852) 05/02/2025 00:45:00.438 | Trade | → Executing Market Order to Buy 1 XAUUSD (SL: 2845, TP: 2852) SUCCEEDED, Position PID2
Serial # Order ID Position ID Event Time (UTC+7) Volume Quantity Type Entry price TP SL Closing price Gross profit Pips Balance Equity
> first thing i notice is the logs not showing pips, only whole points. Does that mean it does n0t know pips?
You have to ask Spotware. That's what they have as output. If you want pips, then you need to calculate them as the difference between the SL/TP and the entry price.
As for the rest of what you provided, it doesn't do anything to help me. If it all seems okay to you, that's fine with me.
Otherwise, you apparently didn't put any of those Print statements I suggested in your code or if you did, you didn't output them.
if (whatever condition is met) {
foreach (Position p in Positions)
{
ClosePositionAsync(p, (TradeResult r) =>
{
if (r.IsSuccessful)
{
Print("Closed position \"{0} {1}\".", p.Id, p.Label);
}
else if (!r.IsSuccessful)
{
Print("WARNING! Could not close position \"{0} {1}\"!", p.Id, p.Label);
Print("Error message: {0}", r.Error.Value.ToString());
}
});
}
}
Right now, I don't even think they're working on or investigating the issue because they've said absolutely nothing and people have been reporting Cloud issues since Nov/Dec.
O_O
So, at this point, I think a good solution might be to get a VPS.
Do you know if cTrader can run on a server with Windows Server 2022?
I've been using VPS for ages. Currently have one with 4GB memory running server 2019. It's doing fine. Here's who I have mine with:
newyorkcityservers . com/billing/aff.php?aff=74
They have awesome customer service and I've never experienced any down time with them except when I had my VPS reimaged from 2012 → 2019, which took me less than an hour to have done and reconfigure one Saturday afternoon.
hi, firemyst, Thank you for your help! This morning I tested the cBot on the latest version of cTrader, and the error message is still the same. However, if I run the cBot locally, everything works fine.
I can't understand the reason.
It's a shame not to be able to use the "On Cloud" setting, which allows the cBot to stay active all day and be managed from any device.
You're welcome.
And I get your frustration.
It's even more frustrating that Spotware doesn't even seem to acknowledge these issues any more, and don't give us any updates on fixes.
Right now, I don't even think they're working on or investigating the issue because they've said absolutely nothing and people have been reporting Cloud issues since Nov/Dec.
If you keep track of all your stop orders in your code, then you know when one is triggered. That is, on every tick see if you have any stop orders in your data structure and if so, check each one to see if the condition is met. If so, place the order as a market order instead so you know when it's placed. Then you can stop checking the other stop orders you have in your queue.
You have to keep track of your swing values and when your indicator value obviously crosses above or below those values, you know they've been taken out.
No, unless you do special coding yourself. That is, save info about your analysis to a file that your devices can read from, and then have an indicator that reads that file and redraws them
I think you might not understand the process, especially since you haven't outlined the steps you follow that aren't working so someone can correct you if need be.
Here's a reference point for you:
help. ctrader. com /ctrader-algo/custom-indicators/
firemyst
07 Mar 2025, 00:12
The issue is, as stated in a multitude of other posts, that the cloud is broken, and you should use a VPS or run locally.
Spotware obviously doesn't care, because they've made no mention of it, or that they're investigating, or something else, with all the user reports of issues with the cloud.
It's been ongoing for weeks.
@firemyst