search Nothing found
Main Algotrading documentation Input parameters

Input parameters

Using the public modifier, you can pass input user parameters to the trading robot, such as stop loss, take profit, and others.



public string StrValue = "Hello word!";
public double FloatValue = 0.5;
public int intValue = 80;
public bool BoolValue=false;

public variables define the program input parameters, they are available from the program properties window.

 It is possible to set a different way to display the names of the input parameters. To do this, use the Parameter keyword, which must be placed before the description of the input parameter in the same string. Thus, the input parameters can be mapped to more user-friendly names.



public enum DayOfWeek : int
public class SomeBot : Bot
[Parameter("My string value")]
public string StrValue = "Hello word!";

[Parameter("My Float value", MinValue = 0, MaxValue = 100)]
public double FloatValue = 0.5;

[Parameter("My integer value", MinValue = 50, MaxValue = 500)]
public int intValue = 80;

public bool BoolValue;
public ValueType EnumValue;
public DayOfWeek UserType = DayOfWeek.Tuesday;

[Parameter("Select Timeframe")]
public TimeFrame TF;

Subscribe to our newsletter and stay up to date with all the news!