Possibility to code with multiple indicators/robots in one dll

Created at 24 Jul 2013, 18:47
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
RO

robgha01

Joined 24.07.2013

Possibility to code with multiple indicators/robots in one dll
24 Jul 2013, 18:47


Hi

Im a developer and a bit new to cAlgo, i use visual studio when i code.

I was wondering if it is possilbe to build multiple robots or indicators in one class library and make cAlgo see them,

 

For example:

I have a project with 3 class libraries called Core, Robots, Indicators and if i have more then one indicator in Indicators library then cAlgo

can not start an instance of it. I works if i only have one indicator/robot but this is bad design if one works in visual studio.

Imagen 50 indicators its 50 class libraries...

 

If not already possible can we add the indicators and robots by code, the pattern is usely named Code-First

for this to be possible we need to be able to set everyting needed by code and let the cAlgo recognise them.

 

Maybe even doing a form of grouping so if you have a dll and all its indicators/robots under it it will show up automaticly but under the name of the dll/naming containing them ?


@robgha01
Replies

cAlgo_Fanatic
25 Jul 2013, 16:52

It is not possible at the moment but we plan to support this in the future.


@cAlgo_Fanatic

robgha01
25 Jul 2013, 18:05

RE:
cAlgo_Fanatic said:

It is not possible at the moment but we plan to support this in the future.

Im glad to hear that :D

If possible to answer:

Will this be added under this year or about how long ?

i dont need an exact time but only a hum on what you think :) (speculation ofc)


@robgha01

cAlgo_Fanatic
31 Jul 2013, 16:28

 It will be implemented most probably this year, but not in the next few months.


@cAlgo_Fanatic

pennyfx
15 Aug 2013, 02:44

I have multiple robots in one DLL and I use them as base classes in cAlgo.


For example:

public class CoolRobot : SuperRobotInDLL {

  // add all public settings 
  [Parameter("Take Profit")]
  public int TakeProfit;

  public override void OnStart(){

  // pass your settings down to the base class here
  base.TakeProfit = this.TakeProfit;
  base.OnStart();
 }
}

There is probably a better way to pass the settings down to the base class, but this works for now.


@pennyfx