Replies

if.mihai@gmail.com
28 Nov 2018, 15:32

RE:

Panagiotis Charalampous said:

Hi Mihai,

Here it is

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 NewcBot : Robot
    {
    
        protected override void OnStart()
        {

            Chart.MouseDown += Chart_MouseDown;
        
        }

        private void Chart_MouseDown(ChartMouseEventArgs obj)
        {
            Print("Time: " + obj.TimeValue);
            Print("Price: " + obj.YValue);
        }

        protected override void OnTick()
        {
            // Put your core logic here
        }

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

We are working on the documentation as well :)

Best Regards,

Panagiotis

I tried to create an indicator based on this,
and tried like few hours (not kidding) to find the Log, where Print() prints

Just to find out (through a random post in forum), that a guy succeeded to Print(), by using a robot instead of indicator.

Ok, I copied-pasted exactly your code, creating a new bot, just to find out where is Log window in cTrader.

I saw a new tab, CBot Log, great, it works now.

But I have a question: isn't it logical to have also an Indicator Log too? Or is it already planned but not implemented yet?


@if.mihai@gmail.com

if.mihai@gmail.com
28 Nov 2018, 10:59

Oh, nice! Super elegant way Thank you very much, i appreciate it
@if.mihai@gmail.com

if.mihai@gmail.com
21 Jun 2018, 07:44

vital feature

the number of votes actually shows how many users of CTrader are programming with it
:))


@if.mihai@gmail.com

if.mihai@gmail.com
14 Nov 2017, 21:15

I really hope cAlgo will soon include needed and sufficient features to put metatrader to rest They have more features, but is always a pain to get something done in their Mql language, and they ignore requests or suggestions for any improvement in user/programmer experience, (i have many years of bad experience with them) That's why i am so hopeful with cTrader/cAlgo. I really want to make the shift to cAlgo, and leave mt4 into the dust.
@if.mihai@gmail.com

if.mihai@gmail.com
16 Oct 2017, 22:59

RE:

Spotware said:

There is no such functionality at the moment. We plan to implement it in future.

Which future?

2017 is already ending

And i'm searching in the forum for mouse click events on chart and on objects

I don't quite get it, really, do we have to wait for 2020 to be able to get time and price under the mouse?


@if.mihai@gmail.com

if.mihai@gmail.com
16 Oct 2017, 22:46

I am also interested in this answer.

Also about events, in general, not only mouseclick() or mouseover()


@if.mihai@gmail.com

if.mihai@gmail.com
16 Oct 2017, 16:03

Also, the slope for each case:

1, price height / bars
2. price height / periods


@if.mihai@gmail.com