I then added a label to each line on the chart using a private string. The attached image shows my indicator menu, a chart and parts of the code to give an idea.
Currently, if I change a timeframe I also need to change the corresponding label/private string. This is how the DrawText code line looks like:
private int timeframea = 60;
...
private string labela = "60";
DrawText("atagup", true, labela, rightend, (LinReg(BarsArray[1],9))[0], 0, riseclr, new Font ("Arial", labelsize, FontStyle.Bold),StringAlignment.Near, Color.Empty, Color.Empty, 0);
Rather than having to type twice each the time frame and then the label separately,
is there perhaps a simpler way so that it accept the chosen timeframe also as the label?
sandman
Comment