Replies

driftingprogrammer
10 Jun 2024, 09:58

RE: RE: RE: RE: RE: allow Algos to start cBots

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.

Here is a short example on how to start a cBot

            var robot = ChartRobots.Add("Sample Break Even", "", 1,1);                  robot.Start();

Best regards,

Panagiotis

Hi Panagiotis,

I understand this API will enable me to add and start cBot to the chart that this particular cBot (starter cBot) is on. Does that mean that now multiple cBots can run on the same chart. Using cTrader Desktop I can never add more than one cBot on a particular chart, so can you please shed some light on this new thing, running multiple cBots on the same chart.

Is there a way to access Robots that are running on other currency pairs and hence their saperate charts but within this particular instance of cTrader and also on this same account (I am running everything locally with synchronisation with cloud turned off).

 

Please let me know,

Cheers.

Hi there,

Using cTrader Desktop I can never add more than one cBot on a particular chart, so can you please shed some light on this new thing, running multiple cBots on the same chart.

This was always possible in the Trade section

Is there a way to access Robots that are running on other currency pairs and hence their saperate charts but within this particular instance of cTrader and also on this same account (I am running everything locally with synchronisation with cloud turned off).

You can access all charts and manage cBots on them using a plug in.

Best regards,

Panagiotis

 

Hi Panagiotis,

Are you saying this can be accomplished by writing a plug-in, or are you saying there is a plug-in available that can do this. Please let me know.

 

Thanks.


@driftingprogrammer

driftingprogrammer
09 Jun 2024, 08:48

RE: RE: RE: allow Algos to start cBots

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.

Here is a short example on how to start a cBot

            var robot = ChartRobots.Add("Sample Break Even", "", 1,1);                  robot.Start();

Best regards,

Panagiotis

Hi Panagiotis,

I understand this API will enable me to add and start cBot to the chart that this particular cBot (starter cBot) is on. Does that mean that now multiple cBots can run on the same chart. Using cTrader Desktop I can never add more than one cBot on a particular chart, so can you please shed some light on this new thing, running multiple cBots on the same chart.

Is there a way to access Robots that are running on other currency pairs and hence their saperate charts but within this particular instance of cTrader and also on this same account (I am running everything locally with synchronisation with cloud turned off).

 

Please let me know,

Cheers.


@driftingprogrammer

driftingprogrammer
07 Jun 2024, 05:31

RE: RE: RE: RE: allow Algos to start cBots

driftingprogrammer said: 

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.

Here is a short example on how to start a cBot

            var robot = ChartRobots.Add("Sample Break Even", "", 1,1);                  robot.Start();

Best regards,

Panagiotis

Hi Panagiotis,

Can you please guide me how I can get access to the object ChartRobots inside my cBot.

Inside my cBot when I write 

Print(Chart.ChartType); 

On running I get the output 

candlesticks

But when I write 

Print(Chart.Robots); 

I get a compilation error saying

Error CS1061: 'Chart' does not contain a definition for 'Robots' and no accessible extension method 'Robots' accepting a first argument of type 'Chart' could be found (are you missing a using directive or an assembly reference?) (/Users/ben/cAlgo/Sources/Robots/EvcBotController/EvcBotController/EvcBotController.cs, line: 25, column: 25)

Can you please guide me how I can get to the ChartRobots object you have mentioned in your code above.

 

Thanks in advance.

 

Hi Panagiotis,

When  I add the below line to the OnStart method of my cBot

Print(ChartRobots.Count);

I get the below error when I run my cBot

07/06/2024 10:58:23.108 | Crashed in OnStart with MissingMethodException: Method not found: 'cAlgo.API.ChartRobots cAlgo.API.Internals.Algo.get_ChartRobots()'.

Please let me know how I can get access to the ChartRobots.

Thanks.


@driftingprogrammer

driftingprogrammer
06 Jun 2024, 16:03

RE: RE: RE: RE: allow Algos to start cBots

driftingprogrammer said: 

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.

Here is a short example on how to start a cBot

            var robot = ChartRobots.Add("Sample Break Even", "", 1,1);                  robot.Start();

Best regards,

Panagiotis

Hi Panagiotis,

Can you please guide me how I can get access to the object ChartRobots inside my cBot.

Inside my cBot when I write 

Print(Chart.ChartType); 

On running I get the output 

candlesticks

But when I write 

Print(Chart.Robots); 

I get a compilation error saying

Error CS1061: 'Chart' does not contain a definition for 'Robots' and no accessible extension method 'Robots' accepting a first argument of type 'Chart' could be found (are you missing a using directive or an assembly reference?) (/Users/ben/cAlgo/Sources/Robots/EvcBotController/EvcBotController/EvcBotController.cs, line: 25, column: 25)

Can you please guide me how I can get to the ChartRobots object you have mentioned in your code above.

 

Thanks in advance.

After I got it to compile at runtime I am getting this error

06/06/2024 21:30:47.580 | Crashed in OnStart with MissingMethodException: Method not found: 'cAlgo.API.ChartRobots cAlgo.API.Chart.get_Robots()'.


@driftingprogrammer

driftingprogrammer
06 Jun 2024, 15:50

RE: RE: RE: allow Algos to start cBots

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.

Here is a short example on how to start a cBot

            var robot = ChartRobots.Add("Sample Break Even", "", 1,1);                  robot.Start();

Best regards,

Panagiotis

Hi Panagiotis,

Can you please guide me how I can get access to the object ChartRobots inside my cBot.

Inside my cBot when I write 

Print(Chart.ChartType); 

On running I get the output 

candlesticks

But when I write 

Print(Chart.Robots); 

I get a compilation error saying

Error CS1061: 'Chart' does not contain a definition for 'Robots' and no accessible extension method 'Robots' accepting a first argument of type 'Chart' could be found (are you missing a using directive or an assembly reference?) (/Users/ben/cAlgo/Sources/Robots/EvcBotController/EvcBotController/EvcBotController.cs, line: 25, column: 25)

Can you please guide me how I can get to the ChartRobots object you have mentioned in your code above.

 

Thanks in advance.


@driftingprogrammer

driftingprogrammer
22 May 2024, 10:06

RE: RE: Can cBot shutdown cTrader

driftingprogrammer said: 

PanagiotisCharalampous said: 

Hi there,

I do not have an easy solution for you, also forcing the entire application to shut down does not sound like a very elegant solution. What is the exact problem you are trying to solve here?

Best regards,

Panagiotis

Thanks for your response.

 

Trendpilot performs very poorly when the spread increases so i want to shutdown ctrader 2 hours before close of day and start ctrader 2 hours after the start of market.

I dont want to close trades before end of the day, i just want to shutdown all the 28 instances of cbot for 4 hours and since trendpilot is a third party cbot the only way i can shut them down automatically, all the 28 instances, is by shutting down ctrader.

 

So my custom cbot was shutting down ctrader after midnight using the API mentioned earlier.

 

Thanks.

Hi Panagiotis,

In order to solve the problem mentioned here I understand that the new API which allows my custom cBot to start stop the purchased cBot will be the most awesome solution.

Can you please share details of this new API.

 

Thanks in advance,

Vipin.


@driftingprogrammer

driftingprogrammer
22 May 2024, 08:24

RE: allow Algos to start cBots

PanagiotisCharalampous said: 

Hi there,

Documentation for this feature will be added soon.

Best regards,

Panagiotis

Hi,

I am desperately wanting to use this feature to stop my purchased cbots before close of market and restarting them after few hours to escape the couple of hours when the spread is too high.

Is the API that enables a cbot to start stop other cbots documented in the API documentation. Please let us know so we can start using this feature.

 

Thanks in advance.


@driftingprogrammer

driftingprogrammer
02 May 2024, 17:21

RE: Can cBot shutdown cTrader

PanagiotisCharalampous said: 

Hi there,

I do not have an easy solution for you, also forcing the entire application to shut down does not sound like a very elegant solution. What is the exact problem you are trying to solve here?

Best regards,

Panagiotis

Thanks for your response.

 

Trendpilot performs very poorly when the spread increases so i want to shutdown ctrader 2 hours before close of day and start ctrader 2 hours after the start of market.

I dont want to close trades before end of the day, i just want to shutdown all the 28 instances of cbot for 4 hours and since trendpilot is a third party cbot the only way i can shut them down automatically, all the 28 instances, is by shutting down ctrader.

 

So my custom cbot was shutting down ctrader after midnight using the API mentioned earlier.

 

Thanks.


@driftingprogrammer

driftingprogrammer
02 May 2024, 07:46 ( Updated at: 02 May 2024, 10:25 )

RE: RE: Can cBot shutdown cTrader

PanagiotisCharalampous said: 

driftingprogrammer said: 

Hi,

 

I was able to use the API System.Environment.Exit(0);

to shutdown ctrader in the earlier versions of ctrader, but in the new version 4.8, using this API is only shutting down the cBot but not the entire cTrader.

 

My requirement is to shutdown the entire instance of cTrader. Is there an API I could use in version 4.8 of ctrader to accomplish this.

 

Please let me know,

Thanks in advance.

cBots now run in separate processes. If you want to close cTrader, you need to find the process and kill it

https://stackoverflow.com/questions/6046916/how-to-close-another-process-from-c-sharp

Thanks for your response,

Can you please guide me how can I identify the parent process. I have 3 profiles of ctrader running on the machine and each profile is running 20 to 100 instances of cBot.

 

Thanks.


@driftingprogrammer

driftingprogrammer
02 May 2024, 07:42 ( Updated at: 02 May 2024, 10:25 )

RE: RE: How to generate the .pwd file for the CLI commands ?

PanagiotisCharalampous said: 

driftingprogrammer said: 

Does the CLI work? Is anyone using it? 

I started my cBot as an external process and it works fine. 

But when I copy the exact same command and try to invoke it from the command prompt by first going to the folder where we have the ctrader-cli.exe I get an error saying the password file needs to be specified. 

When I specify the password file which is a text file with my password it continues to say password file could not be found. I tried all formats of specifying the path but no luck, I always sayd password file not found.

 

Can someone give me an example of a command with the password file specified that works.

 

For me even a simple command like 

 

ctrader-cli.exe symbols --ctid=email@yahoo.com --pwd-file=C:/Users/Administrator/Documents/password.pwd

 

does not work. I am using ICMarkets broker.

 

Thanks in advance.

Hi there,

Can you share screenshots showing where the password file is and the exact message you receive?

Thanks for your response.

 

I am running a simple command - 

ctrader-cli.exe accounts --ctid=myID@yahoo.com --pwd-file=C:\Users\Administrator\Documents\password.pwd

 

This command works fine on my local machine which is Windows 10 professional.

But on my VPS which is running Windows server 2019 I am getting the error - 

Error: Password file not found

I have tried both forward slash and backslash to specify the path but I always get this error on Windows Server 2019 machine.

 

 

 

In this screenshot you can see that the file is available at the specified location and it has the same content as the file on Windows 10 machine where the command works fine.

Thanks.


@driftingprogrammer

driftingprogrammer
02 May 2024, 07:23 ( Updated at: 02 May 2024, 10:25 )

RE: RE: RE: Schedule stop and start of a particular ctrader profile on PC

PanagiotisCharalampous said: 

driftingprogrammer said: 

PanagiotisChar said: 

Hi there,

You can post suggestions here.

You can also use cTrader CLI to interact externally with cBots.

 

Hi,

 

The API System.Environment.Exit(0);

which in version 4.0 use to shutdown the entire ctrader is now only shutting down the cbot and the cbot is restarting after shutting down. 

Is there any API now, which I could use to shutdown that very instance of cTrader, like I was able to do in the older versions with the above API.

Please let me know as this is critical for me, my instance of ctrader is running many instances of a third party cBot which I want to shutdown before the market close (I dont want to close any position, I just want the cBots to shutdown that is why I had been shutting down cTrader itself with the above API).

 

Thanks.

 

cBots now run in separate processes. If you want to close cTrader, you need to find the process and kill it

https://stackoverflow.com/questions/6046916/how-to-close-another-process-from-c-sharp

Thanks for your response.

Can you please guide me on how I can identify the process I need to kill, I have 3 different profiles of cTrader running, each instance running 20 to 80 cbots.


@driftingprogrammer

driftingprogrammer
01 May 2024, 14:34 ( Updated at: 02 May 2024, 07:04 )

Hi,

 

I was able to use the API System.Environment.Exit(0);

to shutdown ctrader in the earlier versions of ctrader, but in the new version 4.8, using this API is only shutting down the cBot but not the entire cTrader.

 

My requirement is to shutdown the entire instance of cTrader. Is there an API I could use in version 4.8 of ctrader to accomplish this.

 

Please let me know,

Thanks in advance.


@driftingprogrammer

driftingprogrammer
01 May 2024, 14:29 ( Updated at: 02 May 2024, 07:04 )

RE: Schedule stop and start of a particular ctrader profile on PC

PanagiotisChar said: 

Hi there,

You can post suggestions here.

You can also use cTrader CLI to interact externally with cBots.

 

Hi,

 

The API System.Environment.Exit(0);

which in version 4.0 use to shutdown the entire ctrader is now only shutting down the cbot and the cbot is restarting after shutting down. 

Is there any API now, which I could use to shutdown that very instance of cTrader, like I was able to do in the older versions with the above API.

Please let me know as this is critical for me, my instance of ctrader is running many instances of a third party cBot which I want to shutdown before the market close (I dont want to close any position, I just want the cBots to shutdown that is why I had been shutting down cTrader itself with the above API).

 

Thanks.

 


@driftingprogrammer

driftingprogrammer
29 Apr 2024, 13:56 ( Updated at: 29 Apr 2024, 14:02 )

Does the CLI work? Is anyone using it? 

I started my cBot as an external process and it works fine. 

But when I copy the exact same command and try to invoke it from the command prompt by first going to the folder where we have the ctrader-cli.exe I get an error saying the password file needs to be specified. 

When I specify the password file which is a text file with my password it continues to say password file could not be found. I tried all formats of specifying the path but no luck, I always sayd password file not found.

 

Can someone give me an example of a command with the password file specified that works.

 

For me even a simple command like 

 

ctrader-cli.exe symbols --ctid=email@yahoo.com --pwd-file=C:/Users/Administrator/Documents/password.pwd

 

does not work. I am using ICMarkets broker.

 

Thanks in advance.


@driftingprogrammer

driftingprogrammer
22 Feb 2024, 16:47

RE: RE: RE: RE: RE: RE: Meet cTrader for Mac

As someone pointed out there is very little difference between the web version and the native mac version at this point.

One very important feature missing in mac like in the web version is to use the filter in the history tab and to be able to see the sum of all the filtered positions net profit.

 

 

Here it shows me the 2 positions that were closed this week based on my search criterion but it does not show the sum of the net profit of these two positions at the bottom.

 

This sum should be made available both on the native mac version and the web version, and it would be a great improvement to both the products.

 

Thanks. 

 


@driftingprogrammer

driftingprogrammer
25 Oct 2023, 06:29 ( Updated at: 25 Oct 2023, 10:53 )

RE: Schedule stop and start of a particular ctrader profile on PC

PanagiotisChar said: 

Hi there,

You can post suggestions here.

You can also use cTrader CLI to interact externally with cBots.

 

Thanks for letting me know about CLI, I should be good to go with my requirements with this tool.

 

Thanks again.


@driftingprogrammer

driftingprogrammer
25 Oct 2023, 05:19 ( Updated at: 25 Oct 2023, 05:20 )

I acomplished this with the following approach

 

To close cTrader few hours before the market close I coded the below cBot

 

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

namespace cAlgo.Robots
{
   [Robot(TimeZone = TimeZones.UTC, AccessRights = AccessRights.FullAccess)]
   public class ShutdownTrendpilot : Robot
   {
       [Parameter("Trade before", DefaultValue = 25, MinValue = 0)]
       public int EndTime { get; set; }

       [Parameter("Trade after", DefaultValue = 4, MinValue = 0)]
       public int StartTime { get; set; }

       [Parameter("Wait in minutes", DefaultValue = 20, MinValue = 0)]
       public int WaitPeriod { get; set; }


       protected override void OnStart()
       {

       }

       protected override void OnBar()
       {
           if (DateTime.Now.TimeOfDay.Hours < StartTime || DateTime.Now.TimeOfDay.Hours > EndTime)
           {
               System.Threading.Thread.Sleep(WaitPeriod * 60 * 1000);
               System.Environment.Exit(0);
           }


       }

       protected override void OnStop()
       {
           // Put your deinitialization logic here
       }
   }
}
 

To start the cBot I wrote a batch file

 

start "" "C:\data\work\trendpilot_demo - Pepperstone cTrader.lnk"

 

And added a schedule in Windows scheduler to invoke the batch file few hours after the market open.

 

Spotware, if you are listening, can you please let me know how I can add an enhancement request to include in API the ability to start stop other third party cBots running in that instance of cTrader.

 

Thanks.


@driftingprogrammer

driftingprogrammer
14 Oct 2023, 18:03

Start Stop a third party cBot

Hi,

The cBot which I want to shutdown 1 hour before the market close and start 1 hour after the market reopen is a third party cBot that I have purchased.

This cBot is called Trendpilot and it does not have a setting to not trade when the spread is very high, because of which it places ridiculous amounts of trades at market start time when the price is going bonkers.

On this computer I have 3 different profiles of cTrader running. I only want to stop and start (2 hours later) this particular profile of cTrader and leave the other 2 profiles of cTrader untouched.

What would be a recommended way to do it.

If someone can provide me a batch file to start and stop a particular profile of ctrader then I can use that batch file and just create an entry in the Windows scheduler to run these batch files one hour before the market closes and one hour after the market opens.

Is it possible to write such a batch file or is AutoHotKey the only way to accomplish this.

Please let me know,

Thanks.


@driftingprogrammer

driftingprogrammer
11 Jun 2023, 10:54

RE:

Spotware said:

Dear traders,

Unfortunately we were not able to reproduce this behavior. If somebody can help us inspect the issue using TeamViewer, please contact us at community@ctrader.com.

Best regards,

cTrader Team

Seems like this is a known issue -

 

The suggested way to deal with this is by somehow fooling the OS to believe it is connected to the monitor so that the Graphic cards continues to render.


@driftingprogrammer

driftingprogrammer
03 Mar 2022, 16:30 ( Updated at: 21 Dec 2023, 09:22 )

RE: RE: RE: RE: Can we buy the whole suit now

Hi,

 

I am not able to download trendpilot anymore, the website does not seem to be working. Please let us know if the cBot is still available, and if it is possible to download the latest version.

 

Thanks,

Vipin.

 

sifneosfx said:

WOW, this is exceptional good results. For sure, the super high volatility of the last week helped a lot. 

Thanks for sharing!

 

driftingprogrammer said:

sifneosfx said:

Hi Ben, 

it makes no sense to run the same asset in two different timeframes, as on one the system may find a sell signal and on the other a buy signal. This will confuse your trading for sure. I strongly recommend to use just one instance of the asset and decide wherever to run it on 4h or 1h. We will not build in such a function to distinct between timeframes as we see it as non productive. 

We will not introduce any new parameters as parameters we have delivered are samples. Because every broker delivers different historically data, the results always vary. It is your duty to find best parameters for any given asset, timeframe, broker.

Customer are informed by mail on new versions. All updates are for customers free, lifetime.

Hope that helps...

driftingprogrammer said:

Hi,

I have been testing your robot on all 30 parameters.

There are 2 markets  which are running on both 1 hr and 4 hr timeframe. By looking at the log output is it possible to make a distinction between the outputs of these 2 robots.

I have found in the last one month the robot has performed extremely poorly on NZDUSD using the default parameters that come with the download. I am unable to assess weather both the instances of NZDUSD are performing poorly or only one of them is performing poorly.

If it is not possible to make that distinction it would be great if such a feature is added sometime in the future,

Is it ok to go ahead and buy the Robot now. After buying the robot when you intriduce new parameters for new markets or update existing parameters for better performance how do you inform the existing customers.

Please let me know.

Thanks in advance.

Cheers.

 

 

Here are the test results of running all the 30 parameters for the last 48 hours, one would think that during these times the robot might fail but he performed much better, while i was not expecting more then 20% monthly return it gave a 40% return in 2 days ->

 

 

 


@driftingprogrammer