Topics
Replies

firemyst
08 Sep 2024, 09:10

RE: RE: Closing part of a position in backtesting

da.weber92 said: 

firemyst said: 

If you wrote your own bot, then you do it in your code by modifying the position and reducing the volume of your position when your criteria are met.

Sorry for being unprecise, but I meant manual backtesting without a bot or even indicators. Just looking at the chart and using a little bit of intuition.

 

I am using hedging for some time now and you can get out of bad trades by partly closing positions quite well. But I can not do that in replay mode or I did not find the option to do this.

Just double click on your order in the order window and the modify order window comes up.

Reduce the volume of your position and click to update your order.


@firemyst

firemyst
07 Sep 2024, 01:17 ( Updated at: 08 Sep 2024, 05:09 )

RE: POOR SERVICE

PanagiotisCharalampous said: 

Hi there,

Telegram is not the place to report your issues. Your emails were not received. Your video has been forwarded to the product team for further investigation.

Best regards,

Panagiotis

@PanagiotisCharalampous:

Here's another report of your team not receiving emails people are sending to the “community” email address. 

I think this should warrant some kind of investigation on Spotware's side to see why as there's now at least 2 users who had sent emails through, but Spotware didn't receive them.

To refresh, here's the thread on an issue I reported where after sending the initial issue to the Community addresses, they didn't receive any further emails from me once I tried sending through my VPS information:

https://ctrader.com/forum/ctrader-algo/44559/#post-113028

 

 


@firemyst

firemyst
07 Sep 2024, 01:13

If you wrote your own bot, then you do it in your code by modifying the position and reducing the volume of your position when your criteria are met.


@firemyst

firemyst
04 Sep 2024, 09:23 ( Updated at: 19 Mar 2025, 08:57 )

RE: RE: RE: RE: RE: RE: RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

firemyst said: 

PanagiotisCharalampous said: 

 

Hi firemyst,

It seems we have not received this email. Can you please resend it to support@ctrader.com?

Best regards,

Panagiotis

Resent as requested. PLease let me know if you received it. If not, I might have to send separate individual emails with all the info as I wonder if your email system might be blocking it or sending it to spam for some reason.

Hi firemyst,

Try my personal one as well support@ctrader.com

Best regards,

Panagiotis

 

Just wanting to confirm you've received the messages I've sent? If not, I think Spotware's email system is blocking them for some reason because all my initial messages got through to the Community team - obviously since they asked for the VPS' details to check out the issue.

 

Thank you

 


@firemyst

firemyst
03 Sep 2024, 11:47 ( Updated at: 19 Mar 2025, 08:57 )

RE: RE: RE: RE: RE: RE: RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

firemyst said: 

PanagiotisCharalampous said: 

 

Hi firemyst,

It seems we have not received this email. Can you please resend it to support@ctrader.com?

Best regards,

Panagiotis

Resent as requested. PLease let me know if you received it. If not, I might have to send separate individual emails with all the info as I wonder if your email system might be blocking it or sending it to spam for some reason.

Hi firemyst,

Try my personal one as well support@ctrader.com

Best regards,

Panagiotis

 

Done.

I've also sent a separate message with the email as a screen capture in case it has been filtered somewhere based on the text.

EDIT:

I just sent you a link too to the private YouTube video I uploaded show casing the issue.

 


@firemyst

firemyst
03 Sep 2024, 09:22 ( Updated at: 19 Mar 2025, 08:57 )

RE: RE: RE: RE: RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

 

Hi firemyst,

It seems we have not received this email. Can you please resend it to support@ctrader.com?

Best regards,

Panagiotis

Resent as requested. PLease let me know if you received it. If not, I might have to send separate individual emails with all the info as I wonder if your email system might be blocking it or sending it to spam for some reason.


@firemyst

firemyst
03 Sep 2024, 06:22

RE: RE: RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

firemyst said: 

PanagiotisCharalampous said: 

Hi firemyst,

Can we have the cBot that reproduces this problem?

Best regards,

Panagiotis

Any updates on this?

  1. I provided a private video link on YouTube demonstrating the issue;
  2. I provided access details to my VPS so the team can see it first hand.
  3. I provided .algo file and source code that reproduces the issue on the VPS
  4. I've provided plenty of details in this thread

Thank you.

Hi firemyst,

We were not able to reproduce this. You said that you will provide access to your VPS but we have not received anything yet.

Best regards,

Panagiotis

I sent the email last week:


@firemyst

firemyst
02 Sep 2024, 23:51

RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

Hi firemyst,

Can we have the cBot that reproduces this problem?

Best regards,

Panagiotis

Any updates on this?

  1. I provided a private video link on YouTube demonstrating the issue;
  2. I provided access details to my VPS so the team can see it first hand.
  3. I provided .algo file and source code that reproduces the issue on the VPS
  4. I've provided plenty of details in this thread

Thank you.


@firemyst

firemyst
30 Aug 2024, 01:01 ( Updated at: 30 Aug 2024, 05:10 )

RE: Bot crash trubleshot

PanagiotisCharalampous said: 

Hi there,

Share your cBot code and send us some troubleshooting information the next time this happens. Please paste a link to this discussion inside the text box before you submit it.

Best regards,

Panagiotis
 

HI @PanagiotisCharampous:

This is another thread where I'm clearly subscribed, but have received no email notifications of any replies again.

Screen capture showing I'm subscribed:

Before you say anything, there are no emails in any spam/junk folder either.

There's definitely an issue here. 

I've noticed so far on all the threads where this has happened, it has been on those where my posts were awaiting moderation before being posted.

 


@firemyst

firemyst
29 Aug 2024, 01:50 ( Updated at: 29 Aug 2024, 05:15 )

Okay. And? Without providing a screen capture showing your attempted orders or the results, I'm not sure how you're expecting anyone to be able to further assist you?


@firemyst

firemyst
29 Aug 2024, 01:49 ( Updated at: 29 Aug 2024, 05:15 )

It would be nice, but right now I don't believe there is any such functionality – it's a manual process.


@firemyst

firemyst
29 Aug 2024, 01:45 ( Updated at: 29 Aug 2024, 05:15 )

See this thread as well, as I'm having similar issues that gives the same error, and am hoping Spotware is actually investigating it:

https://ctrader.com/forum/ctrader-algo/44559/#post-112763

 


@firemyst

firemyst
28 Aug 2024, 08:03

RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

Hi firemyst,

Can we have the cBot that reproduces this problem?

Best regards,

Panagiotis

I have emailed the Community account with details for accessing my VPS so they can see the issue happening first hand. I've explained what to look for in the details of the email.


@firemyst

firemyst
28 Aug 2024, 02:49

If you're writing the output from the bot itself, why not just write the bot's parameters as they currently are in the bot to the output file?

Why would you need to read the parameters of the saved cbotset file when the actual parameters in the bot could have been updated/changed without the cbotset file having been updated?


@firemyst

firemyst
27 Aug 2024, 06:39

RE: RE: I need a bot that closes all operations when the equity rises 20pips

robertocarlosyo said: 

firemyst said: 

Yes, it's possible. :-)

Do you know where I get it?

I didn't say there's already one out there.

However, you can code your own to do it. It's relatively straight forward and not too complex.


@firemyst

firemyst
27 Aug 2024, 00:53

RE: When a bot was "unexpectedly terminated", cTrader shows the bot as still running

PanagiotisCharalampous said: 

Hi firemyst,

Can we have the cBot that reproduces this problem?

Best regards,

Panagiotis

Any updates on this issue? 

I replaced the async call with the synchronous code below, and the issue still occurs for me: the bot instance is still marked as “running”, but it's not doing anything/logging, and/or crashes entirely with the error message above:

if (_p.Pips > MaxTrailingStopDistancePips + 2)
{
    //I tried replacing the async code with the following synchronous api call in the 
    //sample code I sent to Spotware, and the issue still occurs. 
    //Seems 1 instance of cTrader cannot handle 26 running instances of a cbot when using this call
    Print("Moving Stop Loss");
    ModifyPosition(_p,
        (_p.TradeType == TradeType.Buy ? s.Bid - (MaxTrailingStopDistancePips * s.PipSize) : s.Ask + (MaxTrailingStopDistancePips * s.PipSize)),
        _p.TakeProfit.GetValueOrDefault(),
        _p.HasTrailingStop
        );
        
    //ModifyPositionAsync(_p,  
    //    (_p.TradeType == TradeType.Buy ? s.Bid - (MaxTrailingStopDistancePips * s.PipSize) : s.Ask + (MaxTrailingStopDistancePips * s.PipSize)),
    //    _p.TakeProfit.GetValueOrDefault(),
    //    _p.HasTrailingStop,
    //    (TradeResult r) => {
            Print("Moved Stop Loss");
            _waitForAsyncTPToComplete = false;
    //    }
    //    );
    //_waitForAsyncTPToComplete = true;
}

@firemyst

firemyst
26 Aug 2024, 02:23

Yes, it's possible. :-)


@firemyst

firemyst
26 Aug 2024, 02:22

> “Can we use onBar() and onTick() at the same time?”

Yes.

Example where you don't need the OnBar method:

// define at class level
private int _currentIndex;
private int _previousIndex;

//set _currentIndex in OnStart
_currentIndex = _marketSeries.OpenTimes.Count;
_previousIndex = 0;

//Do the following in OnTick
if (_currentIndex != _previousIndex)
{
    //Call your OnBar Method
    YourCustomOnBarForBot([parameters if any]);

    //Update the previous index until it changes again
    _previousIndex = _currentIndex;
}

//if needed, continue with the ontick method
//Or, if you don't want to do anything else with the tick when 
//a new bar is formed, use an else clause
//else do the tick method when it's not the same tick a new bar is formed
else
{
}

@firemyst

firemyst
26 Aug 2024, 02:16

Thoughts are you need to add this to the “Suggestions” forum as Spotware doesn't come here looking for suggestions as this is for technical support.

 

If you really need it done, create your own bot that monitors your positions, and does the SL/TP accordingly as per your parameters.


@firemyst

firemyst
26 Aug 2024, 02:15

First, this needs to go in the “Suggestions” forum as Spotware doesn't look here for suggested improvements. This is for technical help.

 

Second, if it can't wait, I would write your own indicator that will do this for you. I agree cTrader's alerts are 3rd/4th class compared to other platforms out there like MT4 and ThinkTrader's. I don't think Spotware's priority at the moment is improving their alerting functionality as it hasn't changed much in the last 5-8 years. So yeah, probably best way to do this is write your own indicator that monitors prices for you and plays an alert sound meeting your requirements. 


@firemyst