Replies

PanagiotisCharalampous
08 Feb 2024, 09:44

RE: RE: Oops! An Error Occurred

michael.kroll said: 

PanagiotisCharalampous said: 

Hi Michael,

Can you please record a video demonstrating the steps taken to get this error?

Best regards,

Panagiotis

Hi Panagiotis,

thank you for your reply.

As I just started the screen recording, I had to enter the details of the slave account again and what shall I say…. now it worked… :-)

Maybe I had a typo in the account-number or so. Or it was simple mystic…. :-)

Thx a lot and best regards

Michael

Hi Michael,

Probably it was something temporary

Best regards,


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 09:43

RE: RE: cbot licensig intergration

FOREXNUGGETS said: 

PanagiotisCharalampous said: 

Hi there,

It seems you are using a third party licensing service which we are not familiar with. Maybe you should try contacting the licensing service provider first.

Best regards,

Panagiotis

Greetings Panagiotis,

Thank you very much for the response.

l understand your response. in this case which licensing service providers are you familiar with perhaps l can check what they offer.

I haven't used one for ages and I would not be able to support you on that. For such integrations you should get support from the providers directly


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 07:29

RE: cTrader - Plugins

ncel01 said: 

Sounds interesting.

I was reading about this and wondering if, for instance, users will have the possibility to control/manage multiple cBot/CLI instances via these plugins.

Hi ncel01,

Users will have access to charts and will be able to manage only cBots that are already added on these charts. Plugins do not have access to CLI instances since they run outside of cTrader. You can create your own application to manage CLI instances.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 07:04

Hi there,

Plugins have not been released yet. They will be available in cTrader 5.0

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 07:03

Hi Michael,

Can you please record a video demonstrating the steps taken to get this error?

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 07:00

Hi there,

You can use Visual Backtesting and visualize your trades using Deal Map

https://help.ctrader.com/ctrader-automate/backtesting-and-optimizing-cbots/?h=visual+backtesting#real-time-visual-mode-backtesting

If your Deal map is enabled, then when you click on a deal in history, you will see it drawn on the chart


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 06:52

Hi there,

It seems you are using a third party licensing service which we are not familiar with. Maybe you should try contacting the licensing service provider first.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 06:44

Hi acrigney,

If the issue persists, please let us know steps to reproduce it.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 06:39

Hi there,

Done.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
08 Feb 2024, 06:30

Hi there,

If these are suggestions, please post then in the correct section below

https://ctrader.com/forum/suggestions

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
07 Feb 2024, 12:29

RE: RE: Funds not removed

Ding+Dong said: 

 

Thank you,

Can you please also send some troubleshooting information when this happens? To do so, please tap seven times on the logo inside the main menu.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
07 Feb 2024, 07:32

Hi there,

What do you mean when you say “locks up”? How can we reproduce this behavior?

Best regards,

Panagiotis 


@PanagiotisCharalampous

PanagiotisCharalampous
07 Feb 2024, 07:28

RE: RE: RE: RE: Candle Stick Appearance

fufu369 said: 

 

 

PanagiotisCharalampous said: 

fufu369 said: 

PanagiotisCharalampous said: 

You can choose your outline here

 

sure,

 i know how to colorize the outline. but it only colors the wicks instead the outlines of the Candle-body. Like you see in my example: i colored the outlines in black, but the candel-body is still blue.

on other platformes  it colors the wicks AND the candle outlines.

Hi there,

I tried it and works fine for me

 

my problem is half solved.. :D

i just updated my macOS. installed ctrader 100x new .  version of ctrader is 4.8.900. is this correct?

 

 

Hi there, 

We will investigate this further and come back to you.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
07 Feb 2024, 07:11

Hi there,

Plugins will be available in the upcoming major update.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
07 Feb 2024, 07:09

RE: RE: RE: Cant get Trailing StopLoss Working

jmenotts said: 

Thankyou for your reply buddy but ….. im still unable to get it running heres my code it must be something so simple im sure lol.

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo.Robots
{
    [Robot(TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
    public class ADXCrossingBot : Robot
    {
        private bool isTradeOpen = false;

        [Parameter("Quantity (Lots)", Group = "Volume", DefaultValue = 0.01, MinValue = 0.01, Step = 0.01)]
        public double Quantity { get; set; }

        [Parameter("ADX Periods", Group = "ADX", DefaultValue = 20, MinValue = 6, Step = 1, MaxValue = 1000)]
        public int AdxPeriods { get; set; }

        [Parameter("MA", Group = "ADX", DefaultValue = 21, MinValue = 6, Step = 1, MaxValue = 1000)]
        public int TrendMME { get; set; }

        [Parameter("Take Profit", Group = "Risk", DefaultValue = 150, MinValue = 0, Step = 1, MaxValue = 1000)]
        public int TakeProfit { get; set; }

        [Parameter("Stop Loss", Group = "Risk", DefaultValue = 150, MinValue = 0, Step = 1, MaxValue = 1000)]
        public int StopLoss { get; set; }

        [Parameter("Trade Label", DefaultValue = "ADX Crossing")]
        public string TradeLabel { get; set; }

        [Parameter("Use Trailing Stop", DefaultValue = false, Group = "Trailing Stop Loss")]
        public bool UseTSL { get; set; }

        [Parameter("Trigger (pips)", DefaultValue = 20, Group = "Trailing Stop Loss")]
        public int TSLTrigger { get; set; }

        [Parameter("Distance (pips)", DefaultValue = 10, Group = "Trailing Stop Loss")]
        public int TSLDistance { get; set; }

        private DirectionalMovementSystem adx;
        private double volumeInUnits;
        private ExponentialMovingAverage mme;
        private RelativeStrengthIndex rsi;
        

        protected override void OnStart()
        {
            volumeInUnits = Symbol.QuantityToVolumeInUnits(Quantity);
            adx = Indicators.DirectionalMovementSystem(AdxPeriods);
            mme = Indicators.ExponentialMovingAverage(Bars.ClosePrices, TrendMME);
            rsi = Indicators.RelativeStrengthIndex(Bars.ClosePrices, 14);

            Positions.Closed += OnPositionClosed;
        }

        protected override void OnTick()
        {
            // Check if a trade is already open
            if (isTradeOpen)
                return;

            if (adx.DIMinus.Last(3) < adx.DIPlus.Last(3) && adx.DIMinus.Last(1) > adx.DIPlus.Last(1) && adx.DIMinus.LastValue > adx.DIPlus.LastValue)
            {
                if (Symbol.Bid < mme.Result.Last(2))
                    if (rsi.Result.LastValue <= 70)
                    {
                        ExecuteMarketOrder(TradeType.Sell,  Symbol.Name, volumeInUnits, TradeLabel, StopLoss, TakeProfit);
                        isTradeOpen = true;
                    }
            }
            else if (adx.DIPlus.Last(3) < adx.DIMinus.Last(3) && adx.DIPlus.Last(1) > adx.DIMinus.Last(1) && adx.DIPlus.LastValue > adx.DIMinus.LastValue)
            {
                if (Symbol.Bid > mme.Result.Last(2))
                    if (rsi.Result.LastValue >= 30)
                    {
                        ExecuteMarketOrder(TradeType.Buy, Symbol.Name, volumeInUnits, TradeLabel, StopLoss, TakeProfit);
                        isTradeOpen = true;
                    }
            }

{
            // If Trailing Stop Loss is set to true, then we execute the following code block
            if (UseTSL)
            {
                // we iterate through all the instance's positions
                foreach (var position in Positions.Where(x => x.Label == TradeLabel))
                {
                    // If position's pips is above the trailing stop loss pips and the position has not trailing stop loss set
                    if (position.Pips > TSLTrigger && !position.HasTrailingStop)
                    {
                        // We check the position's trade type and excute the relevant code block
                        if (position.TradeType == TradeType.Buy)
                        {
                            // We calculate the stop loss based on the TSL Distance To Add parameter
                            var stopLoss = Symbol.Bid - (TSLDistance * Symbol.PipSize);

                            // We modify the stop loss price
                            position.ModifyStopLossPrice(stopLoss);

                            // We set the trailing stop loss to true
                            position.ModifyTrailingStop(true);

                            Print("Trailing Stop Loss Triggered");
                        }
                        else
                        {
                            // We calculate the stop loss based on the TSL Distance To Add parameter
                            var sl = Symbol.Ask + (TSLDistance * Symbol.PipSize);

                            // We modify the stop loss price
                            position.ModifyStopLossPrice(sl);
                            position.ModifyTrailingStop(true);

                            Print("Trailing Stop Loss Triggered");
                        }
                    }
                }
            }
        }}
        private void OnPositionClosed(PositionClosedEventArgs args)
        {
            // Reset the flag when a position is closed
            isTradeOpen = false;
        }
    }
}

This condition does not allow the TSL code to be executed. Place the TSL code above it

            // Check if a trade is already open
            if (isTradeOpen)
                return;

@PanagiotisCharalampous

PanagiotisCharalampous
06 Feb 2024, 14:21

RE: Cant get Trailing StopLoss Working

jmenotts said: 

Hi im still unable to get it working even with the tried and tested code am i being silly? lol  i pasted the exact code im using, im altering parameters and he results are no different when running back test im lost now any further help will be much appreciated thank you once again.

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo.Robots
{
    [Robot(TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
    public class ADXCrossingBot : Robot
    {
        private bool isTradeOpen = false;

        [Parameter("Quantity (Lots)", Group = "Volume", DefaultValue = 0.01, MinValue = 0.01, Step = 0.01)]
        public double Quantity { get; set; }

        [Parameter("ADX Periods", Group = "ADX", DefaultValue = 20, MinValue = 6, Step = 1, MaxValue = 1000)]
        public int AdxPeriods { get; set; }

        [Parameter("MA", Group = "ADX", DefaultValue = 21, MinValue = 6, Step = 1, MaxValue = 1000)]
        public int TrendMME { get; set; }

        [Parameter("Take Profit", Group = "Risk", DefaultValue = 150, MinValue = 0, Step = 1, MaxValue = 1000)]
        public int TakeProfit { get; set; }

        [Parameter("Stop Loss", Group = "Risk", DefaultValue = 150, MinValue = 0, Step = 1, MaxValue = 1000)]
        public int StopLoss { get; set; }

        [Parameter("Trade Label", DefaultValue = "ADX Crossing")]
        public string TradeLabel { get; set; }

        [Parameter("Use Trailing Stop", DefaultValue = false, Group = "Trailing Stop Loss")]
        public bool UseTSL { get; set; }

        [Parameter("Trigger (pips)", DefaultValue = 20, Group = "Trailing Stop Loss")]
        public int TSLTrigger { get; set; }

        [Parameter("Distance (pips)", DefaultValue = 10, Group = "Trailing Stop Loss")]
        public int TSLDistance { get; set; }

        private DirectionalMovementSystem adx;
        private double volumeInUnits;
        private ExponentialMovingAverage mme;
        private RelativeStrengthIndex rsi;

        protected override void OnStart()
        {
            volumeInUnits = Symbol.QuantityToVolumeInUnits(Quantity);
            adx = Indicators.DirectionalMovementSystem(AdxPeriods);
            mme = Indicators.ExponentialMovingAverage(Bars.ClosePrices, TrendMME);
            rsi = Indicators.RelativeStrengthIndex(Bars.ClosePrices, 14);

            Positions.Closed += OnPositionClosed;
        }

        protected override void OnTick()
        {
            // Check if a trade is already open
            if (isTradeOpen)
                return;

            if (adx.DIMinus.Last(3) < adx.DIPlus.Last(3) && adx.DIMinus.Last(1) > adx.DIPlus.Last(1) && adx.DIMinus.LastValue > adx.DIPlus.LastValue)
            {
                if (Symbol.Bid < mme.Result.Last(2))
                    if (rsi.Result.LastValue <= 70)
                    {
                        ExecuteMarketOrder(TradeType.Sell, Symbol.Name, volumeInUnits, "ADX Sell", StopLoss, TakeProfit);
                        isTradeOpen = true;
                    }
            }
            else if (adx.DIPlus.Last(3) < adx.DIMinus.Last(3) && adx.DIPlus.Last(1) > adx.DIMinus.Last(1) && adx.DIPlus.LastValue > adx.DIMinus.LastValue)
            {
                if (Symbol.Bid > mme.Result.Last(2))
                    if (rsi.Result.LastValue >= 30)
                    {
                        ExecuteMarketOrder(TradeType.Buy, Symbol.Name, volumeInUnits, "ADX Buy", StopLoss, TakeProfit);
                        isTradeOpen = true;
                    }
            }

{
            // If Trailing Stop Loss is set to true, then we execute the following code block
            if (UseTSL)
            {
                // we iterate through all the instance's positions
                foreach (var position in Positions.Where(x => x.Label == TradeLabel))
                {
                    // If position's pips is above the trailing stop loss pips and the position has not trailing stop loss set
                    if (position.Pips > TSLTrigger && !position.HasTrailingStop)
                    {
                        // We check the position's trade type and excute the relevant code block
                        if (position.TradeType == TradeType.Buy)
                        {
                            // We calculate the stop loss based on the TSL Distance To Add parameter
                            var stopLoss = Symbol.Bid - (TSLDistance * Symbol.PipSize);

                            // We modify the stop loss price
                            position.ModifyStopLossPrice(stopLoss);

                            // We set the trailing stop loss to true
                            position.ModifyTrailingStop(true);

                            Print("Trailing Stop Loss Triggered");
                        }
                        else
                        {
                            // We calculate the stop loss based on the TSL Distance To Add parameter
                            var sl = Symbol.Ask + (TSLDistance * Symbol.PipSize);

                            // We modify the stop loss price
                            position.ModifyStopLossPrice(sl);
                            position.ModifyTrailingStop(true);

                            Print("Trailing Stop Loss Triggered");
                        }
                    }
                }
            }
        }}
        private void OnPositionClosed(PositionClosedEventArgs args)
        {
            // Reset the flag when a position is closed
            isTradeOpen = false;
        }
    }
}

Try passing TradeLabel to your orders as well :)


@PanagiotisCharalampous

PanagiotisCharalampous
06 Feb 2024, 13:19

RE: RE: RE: RE: RE: RE: Backtest swaps are still missing in some cases

ncel01 said: 

PanagiotisCharalampous said: 

ncel01 said: 

PanagiotisCharalampous said: 

ncel01 said: 

PanagiotisCharalampous said: 

Hi ncel01,

Can you please provide more information?

Best regards,

Panagiotis

Hi Panagiotis,

Yes, of course. Just let know what exact information you need.

Account, broker and how we can see what you are looking at (cBot, screenshots etc)

Panagiotis,

Try to run a backtest on indices with Pepperstone or Varianse and let me know what the outcome is.

In my case the swaps are zero for all my accounts with these brokers.

Looks good here

Panagiotis,

That's forex. Please try an index, as requested.

Note: My accounts are with Pepperstone Group Limited (ASIC) and not Pepperstone Europe.

Thanks ncel01,

I managed to reproduce this and reported it to the product team. Hopefully it will be resolved soon.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
06 Feb 2024, 12:02

Hi Virtuose,

We have checked your followers accounts and the trades have been rejected due to low margin in their accounts. This was clearly described in the points I have shared above. If your followers thing this should not be the case, they should contact their broker.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
06 Feb 2024, 08:27

RE: RE: RE: RE: Positions didn’t copy to others.

Virtuose said: 

PanagiotisCharalampous said: 

Virtuose said: 

PanagiotisCharalampous said: 

Hi there,

cTrader Copy results are not guaranteed and may vary compared to those of the strategy provider due to the following reasons:

  • Differences between your positions' entry and closing prices and those of the strategy provider
  • Differences in the size of your positions compared to those of the strategy provider
  • Variations in the commissions you pay to your broker compared to those of the strategy provider
  • The possibility that your broker does not offer the same trading symbols used in the strategy
  • Insufficient margin in your account to copy some of the orders executed in the strategy
  • Differences in the stop out levels, which might cause your account to be stopped out, while the strategy provider continues to trade

Best regards,

Panagiotis

If your company does not guarantee 100% copying of positions, why do you still run and offer such a business?

cTrader is not a broker and does not handle trade execution. The platform only facilitated the trade copying process. It cannot guarantee any execution.

man so the fault is from broker side? 

There is no fault. This is how markets work and it is expected. The points above are taken from the EULA which describes the conditions of this service.


@PanagiotisCharalampous

PanagiotisCharalampous
06 Feb 2024, 08:01

RE: RE: Positions didn’t copy to others.

Virtuose said: 

PanagiotisCharalampous said: 

Hi there,

cTrader Copy results are not guaranteed and may vary compared to those of the strategy provider due to the following reasons:

  • Differences between your positions' entry and closing prices and those of the strategy provider
  • Differences in the size of your positions compared to those of the strategy provider
  • Variations in the commissions you pay to your broker compared to those of the strategy provider
  • The possibility that your broker does not offer the same trading symbols used in the strategy
  • Insufficient margin in your account to copy some of the orders executed in the strategy
  • Differences in the stop out levels, which might cause your account to be stopped out, while the strategy provider continues to trade

Best regards,

Panagiotis

If your company does not guarantee 100% copying of positions, why do you still run and offer such a business?

cTrader is not a broker and does not handle trade execution. The platform only facilitated the trade copying process. It cannot guarantee any execution.


@PanagiotisCharalampous