Understanding the name of the indicator in the IndicatorAreas

Created at 05 May 2023, 09:50
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!
AlgoCreators's avatar

AlgoCreators

Joined 16.01.2022

Understanding the name of the indicator in the IndicatorAreas
05 May 2023, 09:50


Hello
How do I know the name of the indicator in the IndicatorAreas?

For example, What is the name of the Chart.IndicatorAreas[0] indicator?


@AlgoCreators
Replies

firemyst
05 May 2023, 17:49

RE:

meeting.chegini said:

Hello
How do I know the name of the indicator in the IndicatorAreas?

For example, What is the name of the Chart.IndicatorAreas[0] indicator?

Try something like this:

Chart.IndicatorAreas[0].Objects[0].Name

Because each indicator area can have more than 1 object in it, you'll have to loop through all the objects to get all their names.


@firemyst

AlgoCreators
07 May 2023, 14:07

RE: RE:

firemyst said:

meeting.chegini said:

Hello
How do I know the name of the indicator in the IndicatorAreas?

For example, What is the name of the Chart.IndicatorAreas[0] indicator?

Try something like this:

Chart.IndicatorAreas[0].Objects[0].Name

Because each indicator area can have more than 1 object in it, you'll have to loop through all the objects to get all their names.

I don't want this!!

I want a code that gives me the name of the oscillator


@AlgoCreators

firemyst
07 May 2023, 14:22

RE: RE: RE:

meeting.chegini said:

firemyst said:

meeting.chegini said:

Hello
How do I know the name of the indicator in the IndicatorAreas?

For example, What is the name of the Chart.IndicatorAreas[0] indicator?

Try something like this:

Chart.IndicatorAreas[0].Objects[0].Name

Because each indicator area can have more than 1 object in it, you'll have to loop through all the objects to get all their names.

I don't want this!!

I want a code that gives me the name of the oscillator

 

I just gave you the general code above on what you have to do.

It's up to you to implement depending on the rest of your code.

I'm not going to write everything for you.

 


@firemyst

AlgoCreators
18 May 2023, 20:45

RE: RE: RE: RE:

firemyst said:

meeting.chegini said:

firemyst said:

meeting.chegini said:

Hello
How do I know the name of the indicator in the IndicatorAreas?

For example, What is the name of the Chart.IndicatorAreas[0] indicator?

Try something like this:

Chart.IndicatorAreas[0].Objects[0].Name

Because each indicator area can have more than 1 object in it, you'll have to loop through all the objects to get all their names.

I don't want this!!

I want a code that gives me the name of the oscillator

 

I just gave you the general code above on what you have to do.

It's up to you to implement depending on the rest of your code.

I'm not going to write everything for you.

 

Dear friend, do you want to teach me how to split the nucleus of an atom?
This is a simple question! If you know the solution, please guide me


@AlgoCreators

firemyst
19 May 2023, 03:48 ( Updated at: 20 May 2023, 16:17 )

RE: RE: RE: RE: RE:

meeting.chegini said:

Dear friend, do you want to teach me how to split the nucleus of an atom?

This is a simple question! If you know the solution, please guide me

How to split the nucleus of an atom: there's plenty of "how to's" on Google and YouTube already on how to do it.


@firemyst

AlgoCreators
20 May 2023, 00:33

RE: RE: RE: RE: RE: RE:

firemyst said:

meeting.chegini said:

Dear friend, do you want to teach me how to split the nucleus of an atom?

This is a simple question! If you know the solution, please guide me

How to split the nucleus of an atom: there's plenty of "how to's" on Google and YouTube already on how to do it.

Guiding you on this issue - I already started. Second post in this thread is how you would start going about doing it through C# code. If you're not trying by writing any code, I'm not writing code for you. Best way to learn is to do it on your own.

If you're just looking at the chart and wondering where they are on the chart, then look for the indicator name on the chart:

 

If the name of the indicator isn't on your chart, then put it there by choosing to display "Indicator Titles":

 

 

I wanted to find out through C# what oscillators are placed on the chart, but I couldn't find a solution. And I think there is no way
And I respect your wrong way of thinking.
Good luck.


@AlgoCreators

jim.tollan
23 May 2023, 16:20 ( Updated at: 23 May 2023, 16:25 )

RE: RE: RE: RE: RE: RE: RE:

meeting.chegini said:

firemyst said:

meeting.chegini said:

Dear friend, do you want to teach me how to split the nucleus of an atom?

This is a simple question! If you know the solution, please guide me

How to split the nucleus of an atom: there's plenty of "how to's" on Google and YouTube already on how to do it.

Guiding you on this issue - I already started. Second post in this thread is how you would start going about doing it through C# code. If you're not trying by writing any code, I'm not writing code for you. Best way to learn is to do it on your own.

If you're just looking at the chart and wondering where they are on the chart, then look for the indicator name on the chart:

 

If the name of the indicator isn't on your chart, then put it there by choosing to display "Indicator Titles":

 

 

I wanted to find out through C# what oscillators are placed on the chart, but I couldn't find a solution. And I think there is no way
And I respect your wrong way of thinking.
Good luck.

You seem to be under the illusion that firemyst is one of your employees. I suggest you adopt a better bedside manner. Thereafter, you'll be pleasantly surprised at the number of folk that  that will be willing to help out with any issues you have. Until then - business as usual.

FWIW - this was the extended approach that firemyst was alluding to:

foreach (var indicatorArea in Chart.IndicatorAreas)
{
    foreach (var indicator in indicatorArea.Objects)
    {
        Print($"Indicator => Area: {indicatorArea.GetType().Name} Name: {indicator.Name}");
    }
}

Whilst it is frustrating to not be presented with the answer that you WANT, sometimes you just have to be grateful that folk have taken the time to point you in the right direction.


@jim.tollan

AlgoCreators
29 May 2023, 19:11

RE:

jim.tollan said:

 

You seem to be under the illusion that firemyst is one of your employees. I suggest you adopt a better bedside manner. Thereafter, you'll be pleasantly surprised at the number of folk that  that will be willing to help out with any issues you have. Until then - business as usual.

FWIW - this was the extended approach that firemyst was alluding to:

foreach (var indicatorArea in Chart.IndicatorAreas)
{
    foreach (var indicator in indicatorArea.Objects)
    {
        Print($"Indicator => Area: {indicatorArea.GetType().Name} Name: {indicator.Name}");
    }
}

Whilst it is frustrating to not be presented with the answer that you WANT, sometimes you just have to be grateful that folk have taken the time to point you in the right direction.

thank you for your help But this code doesn't show anything. Because indicatorArea.Objects.Count =>> 0 And the internal for command is not executed at all

Unfortunately, I am not fluent in English and I use Google translator for help. Maybe I can't ask my question correctly!!


@AlgoCreators